5

When I asked about filesystems with compression I got recommendation to try ZFS. Looks like it worth trying, however I find tools that manage ZFS (zfs, zpool) quite overcomplexified - you need to create some volume, then add it, then create filesystem on it. And finally it suddenly created things in root directory like /qqq/test and it uses /var/run/zfs/zfs_socket (strange for a filesystem).

How to use ZFS (with FUSE) without it's complicated things with volumes, just as good filesystem with compression, something like mount -o loop image.zfs /mnt/qqq -t zfs-fuse?

How to setup ZFS as non-root? FUSE usually means "user can use it too" (example: ntfs-3g). I expect something like this:

$ dd if=/dev/zero of=/home/user/qqq.zfs bs=1M count=100
$ mkfs.zfs /home/user/qqq.zfs -o compress=gzip
$ zfs-fuse /home/user/qqq.zfs /home/user/mnt

Can ZFS be more usual FUSE filesystem that I can add to /etc/fstab and user can install and use on its own?

1 Answer 1

4

Here is something close to what you are looking for, although you would need to be root to achieve it:

$ dd if=/dev/zero of=/home/user/qqq.zfs bs=1M count=100
# zpool create -O compression=gzip -m /home/user/mnt qqq /home/user/qqq.zfs
# chown user /home/user/mnt

ZFS supports non root operations (i.e. delegation) but ZFS-FUSE doesn't implement them.

7
  • OK, then question 2: Suppose some system have working FUSE (e.g. sshfs works), but zpool/zfs/zfs-fuse is not installed at all. How to install ZFS manually and create/mount ZFS as user? I expect it to use /home/user/var/run/zfs, not /var/run/zfs in this case.
    – Vi.
    Sep 4, 2011 at 16:11
  • There is probably no documented way to install ZFS manually as a user on Linux. Given the security implications, I even strongly doubt it to be doable at all.
    – jlliagre
    Sep 4, 2011 at 20:58
  • security? What's wrong if user creates certain big file in his home directory and uses certain FUSE program to mount it to directory (without affecting other users). Security should just like in mkisofs ... -o qqq.iso ; fuseiso qqq.iso $HOME/mnt/myiso.
    – Vi.
    Sep 5, 2011 at 7:04
  • 1
    ZFS, being also an NFS and CIFS service and implementing POSIX ACL, set-uid bits, allowing setting arbitrary and persistent mount points and the likes cannot be implemented/mounted as is by a non root user without compromising the host security. What you are looking for would require to develop a stripped down version of ZFS and this hasn't been done.
    – jlliagre
    Sep 5, 2011 at 12:24
  • 1
    @AnatolyAlekseev It is expected indeed, given the extra file-system layer.
    – jlliagre
    Feb 22, 2023 at 8:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .