Sam's Tech Blog

'You can check out any time you like, But you can never leave!'

2019-08-21

ZFS

How to: ZFS - Quick guide

ZFS

# Set cache file

zpool set cachefile=/etc/zfs/zpool.cache <poolname>

# Limit ZFS on Linux Memory Usage

#1073741824 is 1 GiB. It is good to use at most 50 percent (which is the #default) of the system memory for ZFS ARC to prevent performance #shortage of the host.

echo "options zfs zfs_arc_max=1073741824" >> /etc/modprobe.d/zfs.conf

echo 1073741824 > /sys/module/zfs/parameters/zfs_arc_max

update-initramfs -u