2011-03-17 22:18:13 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
. /lib/dracut-lib.sh
|
|
|
|
|
|
|
|
if [ "$rootfs" = "zfs" ]; then
|
|
|
|
zfsrootfs=`echo "$root" | sed 's|^zfs:||'`
|
|
|
|
zfspool=`echo "$zfsrootfs" | sed 's|/.*||g'`
|
|
|
|
zpool import -N "$zfspool"
|
2011-04-06 16:52:58 +00:00
|
|
|
mount -o zfsutil -t "$rootfs" "$zfsrootfs" "$NEWROOT"
|
|
|
|
if [ "$?" = "0" ]
|
|
|
|
then
|
|
|
|
ROOTFS_MOUNTED=yes
|
|
|
|
else
|
|
|
|
mount -t "$rootfs" "$zfsrootfs" "$NEWROOT" && ROOTFS_MOUNTED=yes
|
|
|
|
fi
|
2011-03-17 22:18:13 +00:00
|
|
|
fi
|