summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorAndrew Morton <akpm@digeo.com>2002-10-12 19:33:20 -0700
committerLinus Torvalds <torvalds@home.transmeta.com>2002-10-12 19:33:20 -0700
commit3f0a23579d4effb5e89bc8ad4e716b982bab9608 (patch)
tree4b3e9ed0dac1f71558d6e7f90cca17b80edc5c8b /scripts
parentbf175bc495d14b8776c001252177c8c8a0342727 (diff)
[PATCH] reduce the dirty threshold when there's a lot of mapped
Dirty memory thresholds are currently set by /proc/sys/vm/dirty_ratio. Background writeout levels are controlled by /proc/sys/vm/dirty_background_ratio. Problem is that these levels are hard to get right - they are too static. If there is a lot of mapped memory around then the 40% clamping level causes too much dirty data. We do lots of scanning in page reclaim, and the VM generally starts getting into distress. Extra swapping, extra page unmapping. It would be much better to simply tell the caller of write(2) to slow down - to write out their dirty data sooner, to make those written pages trivially reclaimable. Penalise the offender, not the innocent page allocators. This patch changes the writer throttling code so that we clamp down much harder on writers if there is a lot of mapped memory in the machine. We only permit memory dirtiers to dirty up to 50% of unmapped memory before forcing them to clean their own pagecache.
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions