Red Hat Bugzilla – Bug 112083
mkinitrd keys lvm1/2 off running system, not kernel version
Last modified: 2007-04-18 13:00:11 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031202
Description of problem:
If I've just installed kernel 2.6, but still haven't booted into it,
mkinitrd will set things up to use lvm version 1, not version 2, in
the 2.6 initrd. This obviously won't work.
Testing the existing devices of the running system is of no use to
decide which lvm version is going to be available when the given
kernel boots. It should probably look at the kernel version number
provided in the command line to decide whether to use lvm1 or lvm2.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.Boot into kernel 2.4, with root in a LV
2.Install kernel 2.6
3.Reboot into it
Actual Results: It won't work, but not only because the LV devices
are not set up. It will fail before it gets to that point, when it
attempts to run the lvm1 programs within kernel 2.6.
Expected Results: Since it's kernel 2.6, it should arrange to use
lvm2, no matter what's being used in kernel 2.4.
It actually fails to initialize variables root_lvm and root_lvm2, but
even if I set root_lvm2=1 in mkinitrd's environment, it fails, because
then it tries *both* lvm1 and lvm2, and the former fails.
Yes, I know -- this was listed in my caveats when I first sent mail
about it to one of the fedora lists. Just wanted to get things
working enough for installs first, migration and upgrades second.
Have a WIP on my laptop that I'm planning to test once I get back to
the office (probably Tuesday)
It actually checks the kernel version now
Confirmed, thanks! (I've only tested this by running mkinitrd for my
FC2test1 install tree within a chroot, from a FC1 boot session, but
that's enough of an indication to me that it works)