Files
scripts-admin-debian/miscellaneous/readme_zfs_8gb_arc_limit.md
2024-11-09 19:40:50 +01:00

23 lines
1.0 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

To limit the amount of RAM allocated to the ZFS ARC cache to 8 GB on TrueNAS, you can adjust a system configuration setting. Heres how to do it:
1. **Access the TrueNAS Interface**: Log in to the TrueNAS web interface.
2. **Open the Shell**: Go to the top menu and click on **Shell** to open a terminal.
3. **Modify the ZFS Configuration**:
- Enter the following command to limit the ARC to 8 GB:
```shell
sysctl vfs.zfs.arc.max=8589934592
```
- This command sets the maximum ARC size to 8 GB (8 GB in bytes = 8589934592).
4. **Make the Change Persistent**:
- To ensure this setting applies on reboot, add it to the startup configuration file.
- Use the following command to append it to `sysctl.conf`:
```shell
echo "vfs.zfs.arc.max=8589934592" >> /etc/sysctl.conf
```
5. **Restart the System**: It's recommended to restart TrueNAS to make sure the setting takes effect.
This will effectively limit the ZFS ARC to 8 GB, allowing more RAM to be available for other processes.