From: Harald Hoyer Date: Tue, 20 Jul 2010 09:23:14 +0000 (+0200) Subject: multipath: install by default, but run only if wwids are present X-Git-Tag: 007~77 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6f9d69c95a835e8db72d912ad8d5d815f2171905;p=thirdparty%2Fdracut.git multipath: install by default, but run only if wwids are present --- diff --git a/modules.d/90multipath/check b/modules.d/90multipath/check index cae205231..b1834b524 100755 --- a/modules.d/90multipath/check +++ b/modules.d/90multipath/check @@ -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 diff --git a/modules.d/90multipath/multipathd.sh b/modules.d/90multipath/multipathd.sh index e26ab84ef..c9a2b3f23 100755 --- a/modules.d/90multipath/multipathd.sh +++ b/modules.d/90multipath/multipathd.sh @@ -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