From: Hannes Reinecke Date: Mon, 27 Mar 2017 00:15:44 +0000 (+1100) Subject: udev-md-raid-assembly.rules: Skip non-ready devices X-Git-Tag: mdadm-4.1-rc1~246 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3a77acd7170199adc690332ded37c41f067c720e;p=thirdparty%2Fmdadm.git udev-md-raid-assembly.rules: Skip non-ready devices If a device isn't fully initialized (e.g if it should be handled by multipathing) it should not be considered for md/RAID auto-assembly. Doing so can cause incorrect results such as causing multipath to fail during startup. There is a convention that the udev environment variable SYSTEMD_READY be set to zero for such devices. So change the mdadm rules to ignore devices with SYSTEMD_READY==0. Signed-off-by: Hannes Reinecke Signed-off-by: NeilBrown Signed-off-by: Jes Sorensen --- diff --git a/udev-md-raid-assembly.rules b/udev-md-raid-assembly.rules index d0d440a6..8ca232a4 100644 --- a/udev-md-raid-assembly.rules +++ b/udev-md-raid-assembly.rules @@ -7,6 +7,9 @@ ENV{ANACONDA}=="?*", GOTO="md_inc_end" SUBSYSTEM!="block", GOTO="md_inc_end" +# skip non-initialized devices +ENV{SYSTEMD_READY}=="0", GOTO="md_inc_end" + # handle potential components of arrays (the ones supported by md) ENV{ID_FS_TYPE}=="linux_raid_member", GOTO="md_inc"