Re: dentry cache leak? Re: rsync out of memory 2.6.8-rc2

From: Klaus Dittrich
Date: Wed Jul 28 2004 - 10:12:29 EST


Nick Piggin wrote:

Klaus Dittrich wrote:

Klaus Dittrich wrote:


I did a test with a value of 500. echo 500 > /proc/sys/vm/vfs_cache_pressure.

The highest numbers a cat /proc/sys/fs/dentry-state then showed during
a du -s were
780721 750505 45 0 0 0

The system survied. No processes were killed.

With vfs_cache_pressure=100 a cat /proc/sys/fs/dentry-state showed
numbers of about 1090000 before processes got killed.

Hope that helps to narrow the region to look for what has changed.

PS. Two concurrent du -s however "kernel: Out of Memory: Killed process .." *
*


Your vfs_cache_pressure probably wants to be higher than 500. Make it 10000.

*No problems when using 10000.
But I think of this as workaround only.

I have read the "Scaling dcache with RCU" article from linuxjournal.com
to get some insight how things should work. Pretty complicated.

I added some printk statements in dcache.c to see what functions
actually get called to shink a dcache during a du -s.
The only one I found is prune_dcache().
Which events should trigger the use of d_invalidate() ?


**
*
-
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/