]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
nfs/parse-nfsroot.sh: don't unset netroot, if not nfs
authorHarald Hoyer <harald@redhat.com>
Fri, 20 Mar 2015 14:48:15 +0000 (15:48 +0100)
committerHarald Hoyer <harald@redhat.com>
Thu, 2 Jul 2015 17:47:46 +0000 (19:47 +0200)
(cherry picked from commit afcc697cb8c588eef68bb635f790991411209089)

modules.d/95nfs/parse-nfsroot.sh

index 9fc2a8c324709436a7fd7dab5f7e2c37b95c406d..a84cd43664b2cd8411edddc3915028956923717f 100755 (executable)
@@ -59,7 +59,14 @@ fi
 
 case "$netroot" in
     /dev/nfs) netroot=nfs;;
-    /dev/*) unset netroot; return;;
+    /dev/*)
+        if [ -n "$oldnetroot" ]; then
+            netroot="$oldnetroot"
+        else
+            unset netroot
+        fi
+       return
+       ;;
     # LEGACY: root=<server-ip>:/<path
     [0-9]*:/*|[0-9]*\.[0-9]*\.[0-9]*[!:]|/*)
         netroot=nfs:$netroot;;