[lkml]   [2007]   [Jan]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC] Limit the size of the pagecache

Rik van Riel wrote:
> Vaidyanathan Srinivasan wrote:
>> In my opinion, once a
>> file page is mapped by the process, then it should be treated at par
>> with anon pages. Application programs generally do not mmap a file
>> page if the reuse for the content is very low.
> Why not have the VM measure this, instead of making wild
> assumptions about every possible workload out there?

Yes, VM page aging and page replacement algorithm should decide on the
relevance of anon or mmap page. However we may still need to limit
total pages in memory for a given set of process.

> There are a few databases out there that mmap the whole
> thing. Sleepycat for one...

That is why my suggestion would be not to touch mmapped pagecache
pages in the current pagecache limit code. The limit should concern
only unmapped pagecache pages.

When the application unmaps the pages, then instantly we would go over
limit and 'now' unmapped pages can be reclaimed. This behavior has
been verified with my fix on top of Christoph's patch.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2007-01-25 07:23    [W:0.117 / U:94.024 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site