[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: BUFCACHEPERCENT.
- To: misc_(_at_)_openbsd_(_dot_)_org
- Subject: Re: BUFCACHEPERCENT.
- From: Chris Cameron <chris_(_at_)_upnix_(_dot_)_com>
- Date: Wed, 9 Jun 2004 13:19:27 -0600
- Organization: UpNIX Internet
A simple 'grep -ri "Some text here" .' in my couple hundred meg Maildir
folder will always take longer the first time than the second time;
when searching for different text too.
$ time grep -ri "dirty shirt" .
6.54s real 0.86s user 1.35s system
$ time grep -ri "hairy back" .
1.96s real 1.21s user 0.24s system
$
Before I raised BUFCACHEPERCENT, I'm certain this wasn't the case as I
often find myself on the phone (in a hurry) trying to find past emails.
I've also just tried this on other OBSD machines I have lying around,
with an unchanged cache and grep's in a row don't seem to speed up
unless the folder is quite small.
This is on 3.4 with mirrored SCSI drives.
Chris
On June 9, 2004 12:36 pm, you wrote:
> On Wed, 9 Jun 2004, Chris Cameron wrote:
> > I know touching the kernel is taboo, but quite recently I've raised
> > my BUFCACHEPERCENT to 25 and have noticed improvements in repeated
> > grep's.
>
> this is a near impossibility if you're using grep from 3.4 or 3.5, as
> it should be using mmap and therefore not touching the buffer cache
> at all.
>
> more details would be interesting.
Visit your host, monkey.org