Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 05 Aug 1995 23:46:16 -0700
From:      David Greenman <davidg@Root.COM>
To:        nate@sneezy.sri.com (Nate Williams)
Cc:        Marc Ramirez <mrami@minerva.cis.yale.edu>, questions@freebsd.org
Subject:   Re: VM question 
Message-ID:  <199508060646.XAA01583@corbin.Root.COM>
In-Reply-To: Your message of "Sun, 06 Aug 95 00:29:36 MDT." <199508060629.AAA13092@rocky.sri.MT.net> 

next in thread | previous in thread | raw e-mail | index | archive | help
>[ Only using 15MB of process space ]
>
>DG>    If you are using 15MB of virtual memory then over time the system can
>DG> potentially page out a large part of that in favor of file caching.
>
>Is there any way we can wire down the maximum percentage of memory used
>by the sytem for file caching, ala the old way of specifying 10% of
>memory for caching, except that this would be an upper limit?

   Not currently. FreeBSD uses all of free memory for caching, and if there
isn't any free memory, it will use "cache pages" and kick the pagedaemon. The
algorithm could be less agressive by not draining free pages down so low and
use a "cache_max" to set an upper bound on the cached pages. ...but then a
lot of free memory will just be wasted most of the time. It really is much
better to use the memory for caching whenever possible.
   We've messed with the algorithm a lot over the past 6 months, and I think
we have a fairly good one right now. Perhaps we should be less aggressive
about paging things out by weighting modified pages more heavily. We currently
treat them almost the same as clean pages. Perhaps there should be a dirty
page threshold of some kind that must be exceeded before paging out any dirty
pages. I dunno...John and I have hashed this and similar questions out dozens
of times and still don't have the perfect solution.

-DG



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199508060646.XAA01583>