lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20070726030902.02f5eab0.akpm@linux-foundation.org>
Date:	Thu, 26 Jul 2007 03:09:02 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Ingo Molnar <mingo@...e.hu>
Cc:	Frank Kingswood <frank@...gswood-consulting.co.uk>,
	Andi Kleen <andi@...stfloor.org>,
	Nick Piggin <nickpiggin@...oo.com.au>,
	Ray Lee <ray-lk@...rabbit.org>,
	Jesper Juhl <jesper.juhl@...il.com>,
	ck list <ck@....kolivas.org>, Paul Jackson <pj@....com>,
	linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: RFT: updatedb "morning after" problem [was: Re: -mm merge plans
 for 2.6.23]

On Thu, 26 Jul 2007 11:40:24 +0200 Ingo Molnar <mingo@...e.hu> wrote:

> 
> * Andrew Morton <akpm@...ux-foundation.org> wrote:
> 
> > On Thu, 26 Jul 2007 11:20:25 +0200 Ingo Molnar <mingo@...e.hu> wrote:
> > 
> > > Once we give the kernel the knowledge that the dentry wont be used again 
> > > by this app, the kernel can do a lot more intelligent decision and not 
> > > baloon the dentry cache.
> > > 
> > > ( we _do_ want to baloon the dentry cache otherwise - for things like 
> > >   "find" - having a fast VFS is important. But known-use-once things 
> > >   like the daily updatedb job can clearly be annotated properly. )
> > 
> > Mutter.  /proc/sys/vm/vfs_cache_pressure has been there for what, 
> > three years?  Are any distros raising it during the updatedb run yet?
> 
> but ... that's system-wide, and the 'dont baloon the dcache' is only a 
> property of updatedb.

Sure, but it's practical, isn't it?  Who runs (and cares about)
vfs-intensive workloads during their wee-small-hours updatedb run?

(OK, I do, but I kill the damn thing if it goes off)

> Still, it's useful to debug this thing.
> 
> below is an updatedb hack that sets vfs_cache_pressure down to 0 during 
> an updatedb run. Could someone who is affected by the 'morning after' 
> problem give it a try? If this works then we can think about any other 
> measures ...
> 
> 	Ingo
> 
> --- /etc/cron.daily/mlocate.cron.orig
> +++ /etc/cron.daily/mlocate.cron
> @@ -1,4 +1,7 @@
>  #!/bin/sh
>  nodevs=$(< /proc/filesystems awk '$1 == "nodev" { print $2 }')
>  renice +19 -p $$ >/dev/null 2>&1
> +PREV=`cat /proc/sys/vm/vfs_cache_pressure 2>/dev/null`
> +echo 0 > /proc/sys/vm/vfs_cache_pressure 2>/dev/null
>  /usr/bin/updatedb -f "$nodevs"
> +[ "$PREV" != "" ] && echo $PREV > /proc/sys/vm/vfs_cache_pressure 2>/dev/null

Setting it to zero will maximise the preservation of the vfs caches.  You
wanted 10000 there.

<bets that nobody will test this>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ