Influence of the swappiness sysctl on the SLES9 Memory management
This document (3469718) is provided subject to the disclaimer at the end of this document.
You have a system with a large amount of memory (more than 16 Gb).
There are some memory demanding applications running but you have calculated that your system should be large enough to cope with that.
slow. It seems that these situations are triggered by high i/o
Checking your available memory you observe that most of the RAM ist
taken by the file system cache.
You try to get your applications more free ram by lowering the kernel sysctl:
This makes the behaviour even worse.
A fix has been introduced with kernel:
2.6.5-7.287.3In order to use the fix, please install this kernel version or above and modify the swappiness via e.g.:
In order to set the value permanently you can edit the file:
and enter the following:
inactive. For a mapped page to be swapped/paged out it must be deactivated
first (deactivated means the page must be moved from the active to the inactive
The code that moves mapped pages from active list to inactive list may be
disabled using certain logic which uses a tunable parameter called
"swappiness". This is meant to control when exactly the code should be
The logic used has a failsafe mechanism which will guarantee the kernel is able
to make progress by swapping / paging out mapped pages. This will happen even
if the other parts of the logic would forbid it.
The failsafe used is the "distress" variable. Before the failsafe can kick in,
the VM will perform a lot of work, resulting in a large number of CPU cycles
being wasted without making progress.
Normally with the default swappiness value, we deactivate mapped pages
regardless of the distress value, so no real cpu cycles are wasted. The CPU
waste becomes visible if swappiness is set to low values (below 40).
Kurt Garloff developed a patch that extends the failsafe mechanism to not only
depend on the distress but to start deactivating the mapped pages when there is
huge imbalance between active and inactive list. This should alleviate the
dependency on the distress value, and it should provide for a more graceful
behavior with low swappiness values, while still retaining similar swappiness
This Support Knowledgebase provides a valuable tool for NetIQ/Novell/SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:3469718
- Creation Date:27-MAR-08
- Modified Date:27-APR-12
- SUSESUSE Linux Enterprise Server
Did this document solve your problem? Provide Feedback< Back to Support Search