ZFS Filesystem Management

Similar filesystems should be grouped together in hierarchies to make management easier. Naming schemes should be thought out as well to make it easier to group administrative commands for similarly managed filesystems.

When a new pool is created, a new filesystem is mounted at /pool.

To create another filesystem:

# zfs create <pool>/<fsname>

To delete a filesystem:

# zfs destroy <fsname>

To rename a ZFS filesystem:

zfs rename <old-name> <new-name>

Properties are set via the zfs set command. To turn on compression:

# zfs set compression=on <pool>/<fsname>

To share the filesystem via NFS:

# zfs set sharenfs=on <pool>/<fsname>
# zfs set sharenfs="mount-options" <pool>/<fsname>

Rather than editing the /etc/vfstab:

zfs set mountpoint=<mountpoint> <pool>/<fsname>

Quotas are also set via the same command:

# zfs set quota=<size> <pool>/<fsname>