]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
fix(multipath): omit module if included with no multipath devices
authorLaszlo Gombos <laszlo.gombos@gmail.com>
Mon, 8 Jul 2024 15:18:01 +0000 (11:18 -0400)
committerNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Mon, 8 Jul 2024 22:49:29 +0000 (18:49 -0400)
Instead of warning the user, lets omit the module to follow
'Principle of Least Surprise'.

modules.d/90multipath/module-setup.sh

index 7bc3043c2421956c70fe41b6f772bbc99c952ee2..4b4e8150b96f0f2231a591ae987d03c49a3273e1 100755 (executable)
@@ -35,8 +35,7 @@ check() {
     require_binaries kpartx || return 1
 
     if [[ $_any_mpath_dev != 0 ]] && [[ ! -f /etc/multipath.conf ]]; then
-        dwarn "multipath: including module with no multipath devices and empty" \
-            "configuration, the root disk may be unintentionally multipathed."
+        return 1
     fi
 
     return 0