Re: Mem issues in 2.6.9 (ever since 2.6.9-rc3) and possible cause

Nick Piggin
2004-10-26T08:01:57Z

Andrew Morton wrote:
> Rik van Riel <riel@redhat.com> wrote:
>
>>- if (referenced && page_mapping_inuse(page))
>>+ if (referenced && sc->priority && page_mapping_inuse(page))
>
>
> Makes heaps of sense, but I'd like to exactly understand why people are
> getting oomings before doing something like this. I think we're still
> waiting for a testcase?

I have found that quite often it is because all_unreclaimable gets set,
scanning slows down, and the OOM killer goes off.

Rik, I wonder if you can put some printk's where all_unreclaimable
is being set to 1, and see if there is any correlation to OOMs?

Aside from that, the patch does make sense, but might be too aggressive.
In heavy swapping loads, the "zero priority" scan might make up a
significant proportion of the scanning done so you'll want to be
careful about regressions there.