[Lunar-commits] <lunar-iso> If an md device is detected enable rd.auto=1 in dracut

Stefan Wold ratler at lunar-linux.org
Sun Jan 12 18:32:47 CET 2014


commit 4538c3330716ef23a3d13c4f37e77b8c5f4c6e46
Author: Stefan Wold <ratler at lunar-linux.org>
Date: Sun, 12 Jan 2014 09:31:35 -0800
URL: https://github.com/lunar-linux/lunar-iso/commit/4538c3330716ef23a3d13c4f37e77b8c5f4c6e46

If an md device is detected enable rd.auto=1 in dracut
---
  lunar-install/sbin/lunar-install | +11/-0    
  1 file changed, 11 insertions(+)

--- a/lunar-install/sbin/lunar-install
+++ b/lunar-install/sbin/lunar-install
@@ -1218,6 +1218,17 @@ EOF
       chmod 0644 $TARGET/var/log/{utmp,wtmp,lastlog}
       chmod 0600 $TARGET/var/log/btmp
 
+      # Tell dracut to auto enable md devices if used during install
+      if [ -e /proc/mdstat ]; then
+        if egrep -q ^md[0-9]+ /proc/mdstat; then
+          cat <<EOF> $TARGET/etc/dracut.conf.d/02-raid.conf
+# Enable software raid automatically using dracut.
+# --  AUTO-GENERATED FILE DO NOT MODIFY --
+kernel_cmdline+=" rd.auto=1"
+EOF
+        fi
+      fi
+
     # really we are done now ;^)
     ) | $DIALOG --title " Installing Lunar-Linux " --gauge "" 10 70 0
 




More information about the Lunar-commits mailing list