]> git.pld-linux.org Git - packages/rc-scripts.git/commitdiff
- rel 4; Don't fail if arrays are already assembled (ex raid10 with 4 devices, one... auto/th/rc-scripts-0.4.16-4
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Fri, 13 Jul 2018 13:24:46 +0000 (15:24 +0200)
committerArkadiusz Miśkiewicz <arekm@maven.pl>
Fri, 13 Jul 2018 13:24:46 +0000 (15:24 +0200)
rc-scripts-git.patch
rc-scripts.spec

index c16153b3b7b3911922612eb1634d84bb60e2d607..fb0b8e3a4dd781c51dfc5cec6302e488af5f2907 100644 (file)
@@ -58,3 +58,30 @@ index f7f0eea..99bb078 100755
        fi
  
        if is_fsmounted usbfs /proc/bus/usb; then
+commit 8903a3b15f08d759d06bb2b02e637e0baf7497bf
+Author: Arkadiusz Miśkiewicz <arekm@maven.pl>
+Date:   Tue Jul 3 15:13:45 2018 +0200
+
+    Don't fail if arrays are already assembled (ex raid10 with 4 devices, one device gets removed/kicked from array).
+
+diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit
+index 99bb078..6fdca19 100755
+--- a/rc.d/rc.sysinit
++++ b/rc.d/rc.sysinit
+@@ -326,8 +326,15 @@ init_mdadm() {
+       fi
+       show "Starting up RAID devices"; busy
+-      /sbin/mdadm --assemble --scan --auto=yes
++      mdadm_out=$(/sbin/mdadm --assemble --scan --auto=yes 2>&1)
+       rc=$?
++
++      if (echo -n "$mdadm_out" | grep -q "Found some drive for an array that is already active:"); then
++              rc=0
++      fi
++
++      echo -n "$MDADM_OUT" >&2
++
+       if [ "$rc" -eq 0 -o "$rc" -eq 2 ]; then
+               # rc is used later too, so set sane value
+               rc=0
index c0f60eb27b100ea5e90c0a1a3fba6a383fd564de..099c004d1cadf9b7d70cc31a37929c7d54371533 100644 (file)
@@ -11,7 +11,7 @@ Summary(pl.UTF-8):    inittab i skrypty startowe z katalogu /etc/rc.d
 Summary(tr.UTF-8):     inittab ve /etc/rc.d dosyaları
 Name:          rc-scripts
 Version:       0.4.16
-Release:       3
+Release:       4
 License:       GPL v2
 Group:         Base
 #Source0:      ftp://distfiles.pld-linux.org/src/%{name}-%{version}.tar.gz
This page took 0.094043 seconds and 4 git commands to generate.