Bug#501259: lvm2: initrd tries to detect lvm volumes too early

Andrew Deason adeason2 at uiuc.edu
Mon Oct 6 05:14:25 UTC 2008


Package: lvm2

Not sure if the problem here is lvm2 or initramfs-tools. On an IBM x330
box, I recently attempted to install lenny with an lvm root. After the
installer rebooted, the lvm pvs/vgs/lvs were not detected, and thus the
machine didn't boot without intervention.

It appears as though the physical drives are not getting detected until
after scripts/local-top/lvm2 is run:

--CUT--

Begin: Mounting root file system[   32.343081] device-mapper: uevent: version 1.0.3
 ... Begin: Runn[   32.408697] device-mapper: ioctl: 4.13.0-ioctl (2007-10-18) initialised: dm-devel at redhat.com
ing /scripts/local-top ...   Volume group "ibm-09" not found
done.
Begin: Waiting for root file system ... [   33.682330] Driver 'sd' needs updating - please use bus_type methods
[   33.761831] sd 0:0:0:0: [sda] 35548320 512-byte hardware sectors (18201 MB)
[   33.846451] sd 0:0:0:0: [sda] Write Protect is off
[   33.954202] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   33.954202] sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[   33.955203] sd 0:0:0:0: [sda] 35548320 512-byte hardware sectors (18201 MB)
[   33.956087] sd 0:0:0:0: [sda] Write Protect is off
[   33.956969] sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[   33.956969]  sda: sda1 sda2 sda3 < sda5 >
[   34.435212] scsi 0:0:8:0: Attached scsi generic sg1 type 3
[   34.435212] sd 0:0:0:0: [sda] Attached SCSI disk
done.
Gave up waiting for root device.  Common problems:
 - Boot args (cat /proc/cmdline)
   - Check rootdelay= (did the system wait long enough?)
   - Check root= (did the system wait for the right device?)
 - Missing modules (cat /proc/modules; ls /dev)
ALERT! /dev/mapper/ibm--09-root does not exist. Dropping to a shell!


BusyBox v1.10.2 (Debian 1:1.10.2-2) built-in shell (ash)
Enter 'help' for a list of built-in commands.

/bin/sh: can't access tty; job control turned off
(initramfs)

--CUT--

(/dev/sda2 is the pv with the vg that contains the root lv on it, in
this case)

If I pvscan and then vgchange manually afterwards, they are picked up
fine. Similarly, if, during the install process (e.g. via late_command),
I put a "sleep 5" in scripts/local-top/00lvm and regenerate the
initramfs, then it works fine.

I don't know if there's something lvm2 can do about this... or does
initramfs-tools need another `udevadm settle' before running the
local-top scripts or something?

-- 
Andrew Deason
adeason2 at uiuc.edu





More information about the pkg-lvm-maintainers mailing list