Kernel update and not the correct kernel on next reboot ...
This is a question we receive a lot on the CentOS forum : "i've updated
my system with yum and it installed a new kernel but it didn't start on
my default kernel ..." Ok, so let explain what happened for sure :
you've installed initially a box with multiple kernels, for example
kernel and kernel-xen (it can be PAE as well ...).
Of course you know how to configure grub and you modify the
/boot/grub/grub.conf to put your default kernel to be the standard one
(because you installed the kernel-xen for testing purposes only ....)
Everything is fine ... until next kernel update : it reverts the default kernel to boot in grub to the kernel-xen ...
Explanations : When you installed both kernels, a file containing a default kernel for the system has been created (/etc/sysconfig/kernel .. check for defaultkernel=) .. and if you installed kernel-xen (for a test maybe ...) this is the default kernel. After a new kernel installation, /sbin/new-kernel-pkg is called to make a new initrd and use grubby to automatically add the newer kernel entry in the grub config file ... If you have a look in this new-kernel-pkg script, you'll see that he uses the /etc/sysconfig/kernel file to …