How do I change the default options for zfs
filesystems on an existing zpool?
That is, ZFS stored for each zpool
pool the default values for new zfs
filesystems. Those are then used by zfs create
as default values if they aren't explicitly overwritten.
I know that zpool
allows to set those default values on creation, by using the capital -O
flag:
zpool create -O atime=off -O compression=on ...
That way, all filesystem creation commands can be shortened from:
zfs create -o atime=off -o compression=on ...
to:
zfs create ...
However, what if I didn't set the -O
on zpool
creation? How can I set or change them for an existing pool?
Update
The following command finally worked for me:
zfs set atime=off compression=on zroot
Thanks to @ewwhite and @shodanshok.