SVN: rc-scripts/trunk/rc.d/rc.sysinit

arekm arekm at pld-linux.org
Fri Dec 16 09:47:24 CET 2011


Author: arekm
Date: Fri Dec 16 09:47:24 2011
New Revision: 12455

Modified:
   rc-scripts/trunk/rc.d/rc.sysinit
Log:
vgscan/vgmknodes/vgdisplay don't support --sysinit option. Back to ignorelocking for these.

Modified: rc-scripts/trunk/rc.d/rc.sysinit
==============================================================================
--- rc-scripts/trunk/rc.d/rc.sysinit	(original)
+++ rc-scripts/trunk/rc.d/rc.sysinit	Fri Dec 16 09:47:24 2011
@@ -617,23 +617,26 @@
 		fi
 		if [ "$lvmversion" = "1" ] ; then
 			modprobe -s lvm-mod >/dev/null 2>&1
+			lvmignorelocking=""
 			lvmsysinit=""
 		elif [ "$lvmversion" = "2" ] ; then
 			modprobe -s dm-mod >/dev/null 2>&1
+			lvmignorelocking="--ignorelockingfailure"
 			lvmsysinit="--sysinit"
 		else
 			modprobe -s lvm-mod >/dev/null 2>&1
 			# device mapper (2.5+ and patched 2.4)
 			modprobe -s dm-mod >/dev/null 2>&1
+			lvmignorelocking=""
 			lvmsysinit=""
 		fi
 
-		run_cmd "Scanning for LVM volume groups" /sbin/vgscan $lvmsysinit
+		run_cmd "Scanning for LVM volume groups" /sbin/vgscan $lvmignorelocking
 		run_cmd "Activating LVM volume groups" /sbin/vgchange -a y $lvmsysinit
 		if [ "$lvmversion" = "2" ]; then
-			/sbin/vgmknodes $lvmsysinit
+			/sbin/vgmknodes $lvmignorelocking
 			# display VG statistics
-			/sbin/vgdisplay -s $lvmsysinit
+			/sbin/vgdisplay -s $lvmignorelocking
 		fi
 	fi
 
@@ -732,7 +735,7 @@
 			# LVM on RAID (keep in sync with LVM setting few lines above)
 			if [ "$golvm" -eq "1" ]; then
 				if [ -x /sbin/vgscan -a -x /sbin/vgchange ]; then
-					run_cmd "Scanning for LVM volume groups (on RAID)" /sbin/vgscan $lvmsysinit
+					run_cmd "Scanning for LVM volume groups (on RAID)" /sbin/vgscan $lvmignorelocking
 					run_cmd "Activating LVM volume groups (on RAID)" /sbin/vgchange -a y $lvmsysinit
 					[ "$lvmversion" = "2" ] && /sbin/vgmknodes
 				fi


More information about the pld-cvs-commit mailing list