Wednesday, September 16, 2009

swappiness parameter

linux 2.6 kernels added a new kernel parameter called swappiness to let the administrators tweak the way linux swaps. it is a no: from 0-100


in essence, higher values leads to more pages being swapped, and lower values leads to more applications being kept in memory, even if they are idle


the default value of swappiness is 60, you can alter it temporarily(until you next reboot) by typing as root:

echo 50 > /proc/sys/vm/swappiness


if you want to alter it permanently then you need to change the vm.swappiness parameter in the /etc/sysctl.conf file

No comments:

Post a Comment