Changing the swappiness to 10

From Useful Data
Jump to navigation Jump to search

Linux does like to spend time swapping stuff out of RAM and is over-zealous in doing so.

To see what the current level of 'swappiness' is:

cat /proc/sys/vm/swappiness

The default is 60. To change it to the recommended 10, edit the file /etc/sysctl.conf (use sudo) and add this line:

vm.swappiness = 10