Bug 718507

Summary: grub2-mkconfig fails to find initrd for old self-compiled kernels
Product: [Fedora] Fedora Reporter: Pavel Roskin <plroskin>
Component: grub2Assignee: Peter Jones <pjones>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 15CC: dennis, lkundrak, mads, pjones
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-10-25 00:01:02 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Pavel Roskin 2011-07-03 18:06:49 UTC
Description of problem:
grub2-mkconfig fails to find the initrd for kernels with names ending with ".old".  Such kernels appear when a self-compiled kernel is installed and a kernel of the same version is already installed.

Using the new initrd with the old kernel is better than using no initrd at all.  The later simply fails to boot, the former is likely to work somehow.

Version-Release number of selected component (if applicable):
grub2-1.98-3.fc14

How reproducible:
Always

Steps to Reproduce:
1. compile kernel and install it
2. install the kernel again
3. run "grub2-mkconfig -o /boot/grub2/grub.cfg"

Actual results:

Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.0.0-rc5+
Found initrd image: /boot/initramfs-3.0.0-rc5+.img
Found linux image: /boot/vmlinuz-3.0.0-rc5+.old
Found linux image: /boot/vmlinuz-2.6.38.8-32.fc15.x86_64
Found initrd image: /boot/initramfs-2.6.38.8-32.fc15.x86_64.img
done

Expected results:

Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.0.0-rc5+
Found initrd image: /boot/initramfs-3.0.0-rc5+.img
Found linux image: /boot/vmlinuz-3.0.0-rc5+.old
Found initrd image: /boot/initramfs-3.0.0-rc5+.img
Found linux image: /boot/vmlinuz-2.6.38.8-32.fc15.x86_64
Found initrd image: /boot/initramfs-2.6.38.8-32.fc15.x86_64.img
done


Additional info:

grub-1.97.1-initramfs.patch should look for both "initramfs-${version}.img" and "initramfs-${alt_version}.img"

Upgrading GRUB 2 to version 1.99 or newer should resolve the problem automatically.

Comment 1 Mads Kiilerich 2011-09-06 23:57:39 UTC
grub2 1.99 is currently testing in Fedora 16.

Comment 2 Pavel Roskin 2011-09-08 02:13:20 UTC
But it's not even in git for Fedora 15.

Comment 3 Mads Kiilerich 2011-09-08 09:50:20 UTC
I doubt the grub maintainer will backport a fix for this relatively minor issue to previous versions. A major version update of such a critical component in a "stable" OS release is probably also not an option without very compelling reasons.

Comment 4 Fedora Admin XMLRPC Client 2011-09-16 19:08:21 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.