ZFS: Difference between revisions

imported>Duckfullstop
m Fix parsing on openzfs sharenfs ipv6 warning
imported>Aidalgol
Add note about how to avoid using ZFS legacy mounting.
Line 85: Line 85:
     };
     };
</syntaxhighlight>
</syntaxhighlight>
Alternatively, if you do not mind maintaining some manual tweaks to your Nix hardware configuarion, you can avoid using the ZFS legacy mounting option if you add <code>options = [ "zfsutil" ];</code> to your filesystem definitions.  e.g. the above would become.
<syntaxhighlight lang="nix">
  fileSystems."/home" =
    { device = "rpool/home";
      fsType = "zfs";
      options = [ "zfsutil" ];
    };
  fileSystems."/backup" =
    { device = "rpool/backup";
      fsType = "zfs";
      options = [ "zfsutil" ];
    };
</syntaxhighlight>
Keep your filesystem defintions in a file separate from <code>/etc/nixos/hardware-configuration.nix</code>, since this is overwritten whenever you run <code>nixos-generate-config</code>.


== Changing the Cache Size ==
== Changing the Cache Size ==