From: Manuel Amador (Rudd-O) Date: Wed, 6 Apr 2011 16:52:58 +0000 (-0700) Subject: Permit both mountpoint=legacy and mountpoint=/ in initrd X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=commitdiff_plain;h=6583dcacdcca2aad7eaec51f31797a3533845099;p=zfs.git Permit both mountpoint=legacy and mountpoint=/ in initrd Signed-off-by: Brian Behlendorf --- diff --git a/dracut/90zfs/mount-zfs.sh b/dracut/90zfs/mount-zfs.sh index 6b742e3..9c753d9 100755 --- a/dracut/90zfs/mount-zfs.sh +++ b/dracut/90zfs/mount-zfs.sh @@ -6,5 +6,11 @@ if [ "$rootfs" = "zfs" ]; then zfsrootfs=`echo "$root" | sed 's|^zfs:||'` zfspool=`echo "$zfsrootfs" | sed 's|/.*||g'` zpool import -N "$zfspool" - mount -o zfsutil -t "$rootfs" "$zfsrootfs" "$NEWROOT" && ROOTFS_MOUNTED=yes + mount -o zfsutil -t "$rootfs" "$zfsrootfs" "$NEWROOT" + if [ "$?" = "0" ] + then + ROOTFS_MOUNTED=yes + else + mount -t "$rootfs" "$zfsrootfs" "$NEWROOT" && ROOTFS_MOUNTED=yes + fi fi