Linux Kernel (Compile)
Following steps are valid for 2.6.18 kernel source on Debian (stable)
Get the source
# apt-get install linux-source-`uname -r`
OR, something like below
# apt-get install linux-source-2.6.18
You might also need the following debian packages
# apt-get install kernel-package libncurses5-dev fakeroot wget bzip2 build-essential udev
Configure kernel parameters
# make menuconfig
You need to do the following if you have tried to compile kernel before
# make clean && make mrproper
Compile (generate .deb)
# make-kpkg clean
# fakeroot make-kpkg --revision=v1 kernel_image
Install .deb
# dpkg -i /usr/src/kernel-image-2.6.18_v1_i386.deb
Create ramdisk (for kernel 2.6.26: just do update-initramfs -c -k 2.6.26-debug )
Do not use mkinitrd, instead use mkinitrd.yaird (devfs is not supported after 2.6.8; udev)
You may need to install the following packages
# apt-get install yaird libhtml-template-perl libparse-recdescent-perl
# emacs /boot/config-2.6.18
and comment out CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" line
# mkinitrd.yaird -o /boot/initrd.img-2.6.18 2.6.18
Update grub and install grub
# emacs /boot/grub/menu.lst
insert initrd /boot/initrd.img-2.6.18 in new grub entries generated by above dpkg -icommand
# grub-install /dev/sda
Everything above was true on: Dec 23, 2008