Configure Linux Swappiness with SaltStack
-
In your SLS file, this section will set your swappiness for your kernel to 10. Modify as needed. The traditional default is 60.
configure_swappiness: file.append: - name: /etc/sysctl.conf - text: vm.swappiness = 10
Swappiness is the controlling value for swap usage behaviour in Linux. Setting it to ten or lower (but rarely zero) is standard for VPS and IaaS machines.