Re: why swap at all?

From: Nick Piggin
Date: Thu May 27 2004 - 01:00:33 EST


Wakko Warner wrote:
Come on, that is quite an exaggeration. It can happen in a span of minutes -- after rsyncing a dir to a backup dir, for example, which fills ram rather quickly with cache I'll never use again. Or after configuring and compiling a package, which does the same thing.


rsync is something known to break the VM's use-once heuristics.
I'm looking at that.


I have a question about that. I keep a debian mirror on one of my machines. there is over 70000 files. If I run find on that tree while it's
downloading the file list, it doesn't take as long. I thought it would be
nice if there was some way I could keep that in memory. The box has 256mb
ram no swap. It is configured as diskless.


You mean that if you prime the cache by running find on the tree,
your actual operation doesn't take as long?

I don't doubt this. Slab cache is shrunk aggressively compared to
page cache. Traditionally I think this has been due at least in
part to some failure cases in the balancing there resulting in slab
growing out of control with some systems.

These failure cases should be fixed now, and slab vs pagecache is
probably something that should be looked at again. I really need
to get my hands on a 2GB+ system before I'd be game to start
fiddling with too much stuff though.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/