]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
dracut.sh: Fix variable name typo.
authorColin Guthrie <colin@mageia.org>
Wed, 5 Feb 2014 10:06:51 +0000 (10:06 +0000)
committerHarald Hoyer <harald@redhat.com>
Fri, 7 Feb 2014 17:05:48 +0000 (18:05 +0100)
This caused the root_dev variable not to be set which in turn meant that
the root device was not whitelisted in 99base/module-setup.sh when injecting
compile-time devexists hooks in hostonly initrds. This ties the generated
initrd to the root fs device (typically the UUID) rather than relying solely
only the root= kernel command line.

While it is hostonly, not hardcoding e.g. UUIDs is still desirable. Any
swap partition on the host device is still added however.

dracut.sh

index ccff358adef8b9f1499fdff88c28c9398b3ed0e9..5267af5ebec544e4d783c345f738a02600a760c1 100755 (executable)
--- a/dracut.sh
+++ b/dracut.sh
@@ -1005,7 +1005,7 @@ if [[ $hostonly ]]; then
         _bdev=$(readlink -f "/dev/block/$_dev")
         [[ -b $_bdev ]] && _dev=$_bdev
         push host_devs $_dev
-        [[ "$_mp" == "/" ]] && root_dev="$_dev"
+        [[ "$mp" == "/" ]] && root_dev="$_dev"
         push host_devs "$_dev"
     done