Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CentOS 7 to AlmaLinux 8 - left over grub entries of old kernels #91

Open
JulianAtkins opened this issue Aug 18, 2024 · 0 comments
Open

Comments

@JulianAtkins
Copy link

Hello everyone, I hope I'm in the right place to report a problem with elevate/leapp.

Once I migrated a CentOS 7 server to AlmaLinux 8, I noticed that the server could NOT reboot to newly installed kernels.

In my /etc/dnf/dnf.conf I have the kernel limit set to 2:

grep installonly_limit /etc/dnf/dnf.conf
installonly_limit=2

I can see the latest kernel properly installed:

rpm -qa |grep -i kernel |sort
kernel-4.18.0-553.16.1.el8_10.x86_64
kernel-4.18.0-553.8.1.el8_10.x86_64

But on boot, I always get the old kernel:

uname -a
Linux server 4.18.0-553.8.1.el8_10.x86_64
ls -la /boot/vmlinuz*
-rwxr-xr-x. 1 root root  5877760 Sep 18  2017 /boot/vmlinuz-0-rescue-e0c9675cb81c416ebcfaa6be69b57691
-rwxr-xr-x. 1 root root 10885560 Jul  2 14:36 /boot/vmlinuz-4.18.0-553.8.1.el8_10.x86_64
-rwxr-xr-x. 1 root root 10886968 Aug  8 14:21 /boot/vmlinuz-4.18.0-553.16.1.el8_10.x86_64

Then I noticed with grubby, that the new kernel does NOT get a grub boot entry:

# grubby --info=ALL | grep ^kernelkernel="/boot/vmlinuz-4.18.0-553.8.1.el8_10.x86_64"
kernel="/boot/vmlinuz-3.10.0-1160.119.1.el7.x86_64"
kernel="/boot/vmlinuz-3.10.0-1160.118.1.el7.x86_64"
kernel="/boot/vmlinuz-0-rescue-e0c9675cb81c416ebcfaa6be69b57691"

Thus, the new kernel is never installed because of the old CentOS 7 boot entries and the dnf installonly_limit. I manually solved the issue by using grubby to remove the two old entries and to add the new kernel.

Could you please check why leapp/elevate failed to remove those old entries from CentOS 7?

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant