System information

Tuning the Memory Management Subsystem 183
15.2.3 Memory Controller (Memory
Cgroups)
If the memory cgroups feature is not needed, it can be switched off by passing
cgroup_disable=memory on the kernel command line, reducing memory consumption
of the kernel a bit.
15.3 Virtual Memory Manager (VM)
Tunable Parameters
When tuning the VM it should be understood that some of the changes will take
time to affect the workload and take full effect. If the workload changes throughout
the day, it may behave very differently at different times. A change that increases
throughput under some conditions may decrease it under other conditions.
15.3.1 Reclaim Ratios
/proc/sys/vm/swappiness
This control is used to define how aggressively the kernel swaps out anonymous
memory relative to pagecache and other caches. Increasing the value increases the
amount of swapping. The default value is 60.
Swap I/O tends to be much less efficient than other I/O. However, some page-
cache pages will be accessed much more frequently than less used anonymous
memory. The right balance should be found here.
If swap activity is observed during slowdowns, it may be worth reducing this pa-
rameter. If there is a lot of I/O activity and the amount of pagecache in the sys-
tem is rather small, or if there are large dormant applications running, increasing
this value might improve performance.
Note that the more data is swapped out, the longer the system will take to swap
data back in when it is needed.