GRUB issues afer kernel update

Some strange issues with GRUB after updates from 9.2 to 9.3 on Hetzner dedicated servers.

After updates new kernel was in second position.

#  grubby --info=ALL | grep ^kernel
kernel="/boot/vmlinuz-5.14.0-284.25.1.el9_2.x86_64"
kernel="/boot/vmlinuz-0-rescue-85f47bbfbf72431286197cf6ff9d0bf1"
kernel="/boot/vmlinuz-5.14.0-362.13.1.el9_3.x86_64"
kernel="/boot/vmlinuz-0-rescue-b890dc22aa144babb696338cefa935db"

# grubby --default-kernel
/boot/vmlinuz-5.14.0-362.13.1.el9_3.x86_64
# grubby --default-index
2

So the first question is, why after updating the new kernel is the 2 index and not the 0 one?
But the main issue was that after the reboot, the old kernel from 9.2 was booted again. To get a new kernel I had to manually do this:

  1. Manually edit /etc/default/grub and set GRUB_DEFAULT from 0 to 2
  2. Manually run:
grub2-mkconfig -o /boot/grub2/grub.cfg

So unclear points:
Why after kernel update the new kernel was in not automatically the first option?
Why after reboot system boot into the old kernel, although grubby showed the default kernel and default index for the new one?

Is this using a hetzner image? Or your own install? It seems like everything is in reverse, at least when I compare with my Rocky install on KVM. I have the 362 kernel at the top of the list in position 0.

This is the default Hetzner image (which is only 9.2 as of now), and update on this fresh image.
A strange thing is that some servers have a new kernel as expected in the highest position (the same as described by you), and some have issues as described in my first post, although all have very similar hardware configuration (AX41 nvme), but different motherboards/bios revisions and maybe something else.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.