For those who share my appreciation of zfs, I will be releasing a patch to zfs-fuse-dracut package that facilitates better functioning when it is used for zfs-root.
Problem: zfs-fuse relies on /proc and /dev for importing new pools. Unfortunately, when it runs from initramfs, systemd, tears down all of it's contents - the only file handles that remain available to zfs-fuse are the ones it already has open at the point the tear-down happens. Workaround: Don't use initramfs. The problem is that this means we need a different pre-root environment for zfs-fuse to run in. What we can use is squashfs running from a raw partition. That does me we need an additional partition on the disk, but that is hardly the end of the world. We simply unpack the initramfs generated, and re-make it as a squashfs. So what we do is we pass to the kernel: root=/dev/werever_we_put_squashfs_partition That gets is booting the pre-root environment, but then we have to do something for the pre-root environment to mount the real rootfs. This is where the new zfs-fuse-dracut patch comes in. It now understands a kernel boot paramter zfsroot=pool/fs, which it will use in preference to root= to determine what FS to use as the rootfs. Effect: Because the rootfs is read-only squashfs it doesn't get torn down, and zfs-fuse remains fully functional, able to import new pools (e.g. from removable media). Side effect: Init fs ends up showing up mounted on /mnt. I will put together a more detailed howto on the conversion of initramfs to squashfs for those that need it once I have released the zfs-fuse-dracut patch. Gordan _______________________________________________ users mailing list [email protected] https://lists.redsleeve.org/mailman/listinfo/users
