From 6bd611763a5afcca2b5606003755c12f269cd71f Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Fri, 25 Feb 2005 17:04:55 +0000 Subject: re-initialize LVM on top of RAID for the mdadm case as well (#149514) --- rc.d/rc.sysinit | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit index 1632be3d..82d43937 100755 --- a/rc.d/rc.sysinit +++ b/rc.d/rc.sysinit @@ -541,7 +541,17 @@ fi update_boot_stage RCraid if [ -f /etc/mdadm.conf ]; then - /sbin/mdadm -A -s + /sbin/mdadm -A -s + # LVM2 initialization, take 2 + if [ -c /dev/mapper/control -a -x /sbin/lvm.static ]; then + if /sbin/lvm.static vgscan > /dev/null 2>&1 ; then + action $"Setting up Logical Volume Management:" /sbin/lvm.static vgscan --mknodes --ignorelockingfailure && /sbin/lvm.static vgchange -a y --ignorelockingfailure + fi + fi + # LVM initialization, take 2 (it could be on top of RAID) + if [ -e /proc/lvm -a -x /sbin/vgchange -a -f /etc/lvmtab ]; then + action $"Setting up Logical Volume Management:" /sbin/vgscan && /sbin/vgchange -a y + fi fi if [ -f /etc/raidtab ]; then -- cgit