2005-03-24 23:28:54

by Bill Nottingham

[permalink] [raw]
Subject: bad caching behavior in 2.6.12rc1

When I upgraded from 2.6.11 to 2.6.12rc1, the VM started
behaving really badly with respect to caching.

Test box is a 1.5GB laptop.

In typical use, I would open a mailbox A, and then switch
to mailbox B. Immediately switching back to mailbox A, I
would find out it was no longer cached. (Using maildirs,
FWIW.)

Looking at /proc/meminfo, I would see:

LowFree: 8-12MB
HighFree: 300-400MB
Cached: 100-200MB

i.e., it was evicting cache when there was plenty of highmem
available for use.

When going back to 2.6.11, and using the same sort of the
workload, the caching would behave more as expected.

Bill


2005-03-24 23:39:54

by Andrew Morton

[permalink] [raw]
Subject: Re: bad caching behavior in 2.6.12rc1

Bill Nottingham <[email protected]> wrote:
>
> When I upgraded from 2.6.11 to 2.6.12rc1, the VM started
> behaving really badly with respect to caching.
>
> Test box is a 1.5GB laptop.
>
> In typical use, I would open a mailbox A, and then switch
> to mailbox B. Immediately switching back to mailbox A, I
> would find out it was no longer cached. (Using maildirs,
> FWIW.)
>
> Looking at /proc/meminfo, I would see:
>
> LowFree: 8-12MB
> HighFree: 300-400MB
> Cached: 100-200MB
>
> i.e., it was evicting cache when there was plenty of highmem
> available for use.

Where's the rest of the memory gone? A full /proc/meminfo would be useful.

2005-03-25 17:53:57

by Bill Nottingham

[permalink] [raw]
Subject: Re: bad caching behavior in 2.6.12rc1

Andrew Morton ([email protected]) said:
> > Test box is a 1.5GB laptop.
> >
> > In typical use, I would open a mailbox A, and then switch
> > to mailbox B. Immediately switching back to mailbox A, I
> > would find out it was no longer cached. (Using maildirs,
> > FWIW.)
> >
> > Looking at /proc/meminfo, I would see:
> >
> > LowFree: 8-12MB
> > HighFree: 300-400MB
> > Cached: 100-200MB
> >
> > i.e., it was evicting cache when there was plenty of highmem
> > available for use.
>
> Where's the rest of the memory gone? A full /proc/meminfo would be useful.

In the manner of all good bugs, as soon as I tried to reproduce it, it's
hiding. I can get it to this point (very little lowfree, lots of highfree,
medium amounts of cache); but now the cache is behaving more as expected.

Feel free to ignore it until I can duplicate it again. :)

Bill