dracut.sh: check for /sbin /bin /lib
authorHarald Hoyer <harald@redhat.com>
Wed, 24 Jul 2013 11:43:32 +0000 (13:43 +0200)
committerHarald Hoyer <harald@redhat.com>
Wed, 24 Jul 2013 11:43:32 +0000 (13:43 +0200)
use readlink to detect, if /usr has to be mounted

dracut.sh

index 8ccec17..d6da06d 100755 (executable)
--- a/dracut.sh
+++ b/dracut.sh
@@ -863,13 +863,13 @@ if [[ $hostonly ]]; then
     for mp in \
         "/" \
         "/etc" \
-        "/usr" \
-        "/usr/bin" \
-        "/usr/sbin" \
-        "/usr/lib" \
-        "/usr/lib64" \
+        "/bin" \
+        "/sbin" \
+        "/lib" \
+        "/lib64" \
         "/boot";
     do
+        mp=$(readlink -f "$mp")
         mountpoint "$mp" >/dev/null 2>&1 || continue
         _dev="$(readlink -f "/dev/block/$(find_block_device "$mp")")"
         [[ "$_mp" == "/" ]] && root_dev="$_dev"