Proxmox ZFS ARC Tuning

Joe Sirianni
1 min readApr 14, 2021

Proxmox supports OpenZFS out of the box. Snapshots, replication, and advanced integrity features are the primary reasons why ZFS is an attractive host filesystem for a virtualization platform.

It is common for ZFS to be discounted as a RAM hog. This is partially true for out of the box configurations, where ZFS will attempt to use half of the system’s memory for the ARC. When it comes to virtualization platforms, low overhead is ideal so more resources can be allocated to the guest systems.

The default zfs_arc_max value is 1/2 of all available ram. Under memory pressure from applications that cache space will be released for the apps much like the page cache. — Brian Behlendorf

If you wish to set a hard upper limit for ZFS ARC memory consumption, you can do some tuning with “/etc/modprobe.d/zfs.conf”

  1. Edit /etc/modprobe.d/zfs.conf, which is likely empty or not created.
  2. Set zfs_arc_min and zfs_arc_max
  3. Run update-initramfs -u
  4. Reboot

Both zfs arc parameters are in bytes, for example:

# 1GiB
options zfs zfs_arc_min=1073741824
# 4GiB
options zfs zfs_arc_max=4294967296

A minimum of 1GiB and maximum of 4GiB is simply an example. Your configuration will likely require different values. ZFS will perform better with more memory. When running along side a virtualization platform, it may be desirable to limit the upper bound of ZFS memory usage.

--

--