How to compile a kernel:
Download the kernel sources from ftp.kernel.org or your mirrors. Verify the signature with:
gpg --verify <kernel-version.sign>
Backup the old .config file in /tmp
Copy the old .config to NEW kernel sources directory
Patches: If you have any patches then
cd /usr/src/NEW_LINUX
patch –dry-run -p1 < name_of_patch_file
Run make oldconfig
make xconfig -----> GUI
make menuconfig ----> ncurses based
After you make all choices save settings into .config file
Run$ nice +19 make bzImage
$ nice +19 make modules This will take a long time so go to sleep...
Run make modules_install
Warning: This will install modules in /lib/modules directory.
cp /usr/src/linux-your-version/arch/i386/boot/bzImage /boot/vmlinuz-your-version
cp /usr/src/linux-your-version/System.map /boot/System.map-2.6.11-version
cp /usr/src/linux-your-version/.config /boot/config-2.6.11-version
Unlink the old vmlinuz, initrd
Now execute, mkinitrd -k vmlinuz-2.6.11-version -i initrd-2.6.11-version -b /boot
If you have a splash image then (check www.bootsplash.de) enable bootsplash option in the kernel config file .config,
mkinitrd -k vmlinuz-2.6.11.10 -i initrd-2.6.11.10 -s 1024x768 -b /boot
Create softlinks to new vmlinuz, initrd
Edit your grub menu.lst if required
Reboot immediately and check. Don't suspend the machine in which case if you reboot with your NEW kernel data corruption will happen.