Configuring Tunables
3 minute read.
Last Modified 2022-09-21 13:03 -0400Be careful when adding or editing the default tunables. Changing the default tunables can make the system unusable.
TrueNAS allows you to add system tunables from the web interface. You can manually define tunables, or TrueNAS can run an autotuning script to attempt to optimize the system. Tunables are used to manage TrueNAS sysctls, loaders, and rc.conf options.
- loader specifies parameters to pass to the kernel or load additional modules at boot time.
- rc.conf enables system services and daemons and only takes effect after a reboot.
- sysctl configures kernel parameters while the system is running and generally takes effect immediately.
Adding a sysctl, loader, orrc.conf option is an advanced feature. A sysctl immediately affects the kernel running the TrueNAS system, and a loader can adversely affect the TrueNAS boot process. Do not create a tunable on a production system before testing the ramifications of that change.
To configure a tunable, go to System > Tunables and click ADD.
Select the Type of tunable to add or modify. Enter the name of the loader, sysctl, or rc.conf variable to configure.
Next, enter the value to use for the loader, sysctl, or rc.conf.
If you wish to create the system tunable but not immediately enable it, unset the Enabled checkbox. Configured tunables remain in effect until deleted or Enabled is unset.
We recommend restarting the system after making sysctl changes. Some sysctls only take effect at system startup, and restarting the system guarantees that the setting values correspond with what the running system uses.
TrueNAS provides an autotune script that optimizes the system depending on the installed hardware.
For example, if a pool exists on a system with limited RAM, the autotune script automatically adjusts some ZFS sysctl values to minimize memory starvation issues. Autotuning can introduce system performance issues. You must only use it as a temporary measure until you address the underlying hardware issue. Autotune always slows a RAM-starved system as it caps the ARC.
We do not recommend TrueNAS Enterprise customers use the autotuning script, as it can override any specific tunings made by iXsystems Support.
Enabling autotune runs the autotuner script at boot. To run the script immediately, reboot the system.
Any tuned settings appear in System > Tunables.