Re: tcp_v4_proxy_lookup()

Bill Hawes (whawes@star.net)
Fri, 19 Sep 1997 08:27:12 -0400


Matthias Urlichs wrote:
> I have the exact same problem with our News server, only more so.
>
> No good solution has been found yet. The simple but unfortunately wrong
> thing to do, i.e. to alternately use the three memory areas for reclamation
> of space, won't work.
>
> IMHO the best way to work around this is to periodically (with an
> adjustable period) use the 'other' allocation methods even if the one
> currently preferred doesn't fail. I'll write up a patch for that. Swapctl
> has enough unused parameters anyway. ;-)

If I may offer a suggestion: rather than playing around with the state
transitions, why not define some parameters setting the target goal for
page cache and buffer cache, and then take actions based on these goals?

For example, let's say you want 25% of memory in buffers and 40% in page
cache. At some point in time buffers are at 20% and page cache at 30%,
so you preferentially use the swap_out option to free memory.

If you had too much page cache and not enough buffers, you would look
for inode pages in shrink_mmap, but ignore buffer pages.

Sound reasonable? Shouldn't be too hard to implement ...

Regards,
Bill