Some of the above steps or even all of them may be completed by the kernel installation script available in your distribution. Still, very often they have to be done manually. In such a case you can use the following script, which allows you to download, compile and install the latest stable kernel, after adjusting it to suit your system configuration:
#! /bin/sh # Patch to the kernel source directory SRC_PATH="/usr/src/kernel/linux-stable" OBJ_PATH="$SRC_PATH-obj/" cd $SRC_PATH # Download the latest -stable ketchup 2.6 # Save the version VER=`ketchup -m` # Generate the configuration file (based on the old one) make O=$OBJ_PATH oldconfig # Build the kernel make O=$OBJ_PATH # Install modules sudo make O=$OBJ_PATH modules_install # Copy the compressed kernel image into /boot sudo cp $OBJ_PATH/arch/i386/boot/bzImage /boot/vmlinuz-$VER # Copy System.map into /boot sudo cp $OBJ_PATH/System.map /boot/System.map-$VER # If you use Fedory, you have to generate the Fedora initrd sudo /sbin/new-kernel-pkg --make-default --mkinitrd --depmod --install $VER
Generally, each distribution has its own preferred method of building and
installing new kernels. The following table contains the links to the kernel
installation instructions for several selected distributions:
To learn more about the configuration and compilation of the Linux kernel you can refer to the book Linux Kernel in a Nutshell by Greg Kroah-Hartman (http://www.kroah.com/lkn/).