From 1a9c4d5d7001638d810dc4c59f2d3e163f4016fb Mon Sep 17 00:00:00 2001 From: yury Date: Fri, 27 Oct 2006 07:11:39 +0000 Subject: [PATCH] - drop not directory dentries in ll_drop_dentry(). Let's see if it helps with OOM on clients. --- lustre/llite/dcache.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lustre/llite/dcache.c b/lustre/llite/dcache.c index 46e4dbb..5d09d1b 100644 --- a/lustre/llite/dcache.c +++ b/lustre/llite/dcache.c @@ -202,6 +202,14 @@ int ll_drop_dentry(struct dentry *dentry) * sys_getcwd() could return -ENOENT -bzzz */ #ifdef LUSTRE_KERNEL_VERSION dentry->d_flags |= DCACHE_LUSTRE_INVALID; + + /* + * XXX: Try to drop negative not directory dentries to check if + * this is source of OOM on clients on big numbers of created + * files. --umka + */ + if (!dentry->d_inode || !S_ISDIR(dentry->d_inode->i_mode)) + __d_drop(dentry); #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)) __d_drop(dentry); if (dentry->d_inode) { -- 1.8.3.1