Modify the boot loader, (a) for GRUB or (b) for LILO.
(a) GRUB: Edit the /boot/grub/grub.conf configuration file:
vi /boot/grub.conf
The file should have the following look:
-------------------------------
default=0
timeout=10
splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-27.7.vserver.rc2)
root (hd0,0)
kernel /vmlinuz-2.4.18-27.7.vserver.rc2 ro root=/dev/sda5
initrd /initrd-2.4.18-27.7.vserver.rc2.img
title Red Hat Linux (2.4.18-27.7.vserver)
root (hd0,0)
kernel /vmlinuz-2.4.18-27.7.vserver ro root=/dev/sda5
initrd /initrd-2.4.18-27.7.vserver.img
title Red Hat Linux (2.4.18-3)
root (hd0,0)
kernel /vmlinuz-2.4.18-3 ro root=/dev/sda5
initrd /initrd-2.4.18-3.img
-----------------------------------------
default=0 means that GRUB would take the first title record,
i.e., our new kernel (vmlinuz-2.4.18-27.7.vserver.rc2), as the boot image.
GRUB loader would update the kernel automatically after reboot.
(b) LILO:
Step 1. Modify the lilo.conf configuration file:
# vi /etc/lilo.conf
Change the "image" and "initrd" settings lines for the linux_patched section:
image=/boot/vmlinuz-2.4.18-27.7.vserver.rc2
initrd=/boot/initrd-2.4.18-27.7.vserver.rc2.img
Important!
Do not delete the base kernel image settings section (linux)!
If you delete these lines and something goes wrong with the new kernel installation,
your system would not start!
After these changes, lilo.conf would look like:
-----------------------------------------------
prompt
timeout=50
default=linux_patched
boot=/dev/sda
map=/boot/map
install=/boot/boot.b
message=/boot/message
linear
image=/boot/vmlinuz-2.4.18-3
label=linux
initrd=/boot/initrd-2.4.18-3.img
read-only
root=/dev/sda5
image=/boot/vmlinuz-2.4.18-27.7.vserver.rc2 # modified
label=linux_patched
initrd=/boot/initrd-2.4.18-27.7.vserver.rc2.img # modified
read-only
root=/dev/sda5
----------------------
Step 2. Type lilo to apply changes:
# lilo
You will see the line:
Added linux_patched *