SEARCH :

Custom Search

Tuesday, April 17, 2007

How to Compile or Recompile Kernel 2.6

Firstly for a newbie like me, hearing a "compile kernel" word was very scary. I think compiled the kernel was a difficult work. That's bad think start when i look my computer lab administrator compiled kernel 2.4.18 to kernel 2.4.33, there was many option and choice in kernel menu ( he use make config) if you already tried to compile kernel, you know that 'make config' are kernel configuration with text interface. If we choose just one false option, we must do it again from the start configuration process ( is very bad,right? ^^ i thought it just for an expert people =P) .

Why i compile kernel if it's very scary think ? Some day i want to make my own livecd but unlucky the proses need kernel 2.6.20 and what i see with 'uname -a' ? my kernel are 2.6.13.. very2 bad you know,i must upgrade the kernel to 2.6.20 and i can't do it...!!! In other way i really-really wan to see my livecd cd become succesfull because i want to give it to my girlfriend =P as her birthday gift, an linux with her photo at booting and many funny think like tux games and many more. In other way i also want to make livecd for my faculty Linux Roadshow. ^^

For her i tried to search how to compile kernel or in specific word " how to upgrade my kernel into kernel 2.6.20 " in uncle google. I read many article about compile kernel and i did some experiment with my kernel. After 6 hour's read and read and then try,i succesfully do it.^^
what i do step by step?
1. Download the kernel source ( i download kernel 2.6.20 from http://www.kernel.org )
2. Extrack it in /usr/src directory
3. ln -s kernel-2.6.20 linux
4. cd linux
5. make menuconfig
in this step you must configure your kernel, for easy way just write down what hardware that your computer have in pice of paper and then choose option from kernel menu depend on your paper before. Example: if your processor was Pentium 4,search the option about processor and then select pentium 4 option, motherboard, soundcard same like that.
6. make modules
7. make modules install
8. wait after compile process finished, and then copy the arch/i386/boot/vmlinuz-file to /boot
9. Configure your grub bootloader, add this line on your grub.conf ( on /boot/grub/grub.conf )
title new kernel 2.6.20
root (hd0,(your partition number))
kernel /boot/vmlinuz-2.6.20 ro root=/dev/hda1
10. Restart your computer and then choose new kernel to try it.^^
If everything great, you now have kernel 2.6.20.. u can check it with 'uname -a' utility.
example:
# uname -a
result ==> Linux fecore.ikom 2.6.11-1.1369_FC4 #1 Thu Jun 2 22:55:56 EDT 2005 i686 i686 i386 GNU/Linux
May be i make some mistake, if you find it you can correct me.. I really need it...=)
Now i didn't afraid any more to compiled my kernel.. How about my livecd? My harddisk broken.. and all my data disepear hiks3...=(

1 comment:

Anonymous said...

Who knows where to download XRumer 5.0 Palladium?
Help, please. All recommend this program to effectively advertise on the Internet, this is the best program!