]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
multipath: install by default, but run only if wwids are present
authorHarald Hoyer <harald@redhat.com>
Tue, 20 Jul 2010 09:23:14 +0000 (11:23 +0200)
committerHarald Hoyer <harald@redhat.com>
Tue, 20 Jul 2010 09:23:14 +0000 (11:23 +0200)
modules.d/90multipath/check
modules.d/90multipath/multipathd.sh

index cae205231615cb0226f7fccf4db2773e95789061..b1834b524a6c4bfce32ede9b0c136b6ebc61173a 100755 (executable)
@@ -14,10 +14,12 @@ is_mpath() {
     return 1
 }
 
-# Do mpath if we appear to be using it for /
-rootdev=$(find_root_block_device)
-if [[ $rootdev ]]; then
-    check_block_and_slaves is_mpath "$rootdev" && exit 0
+if [[ $1 = -h ]]; then
+    rootdev=$(find_root_block_device)
+    if [[ $rootdev ]]; then
+        check_block_and_slaves is_mpath "$rootdev" && exit 0
+    fi
+    exit 1
 fi
 
-exit 1
+exit 0
\ No newline at end of file
index e26ab84ef22b0694bac2f7442bff6b0d20076471..c9a2b3f236cdc394c448e2557d350e7df7546805 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-if [ -e /etc/multipath.conf ]; then
+if [ -e /etc/multipath.conf -a -e /etc/multipath/wwids ]; then
     modprobe dm-multipath
     multipathd
 else