Re: Increase dirty_ratio and dirty_background_ratio?

Linus Torvalds
2009-01-08T16:49:00Z

On Thu, 8 Jan 2009, David Miller wrote:

> From: Andrew Morton <akpm@linux-foundation.org>
> Date: Thu, 8 Jan 2009 03:02:45 -0800
>
> > The kernel can't get this right - it doesn't know the usage
> > patterns/workloads, etc.
>
> I don't agree with that.

We can certainly try to tune it better.

And I do agree that we did a very drastic reduction in the dirty limits,
and we can probably look at raising it up a bit. I definitely do not want
to go back to the old 40% dirty model, but I could imagine 10/20% for
async/sync (it's 5/10 now, isn't it?)

But I do not want to be guided by benchmarks per se, unless they are
latency-sensitive. And one of the reasons for the drastic reduction was
that there was actually a real deadlock situation with the old limits,
although we solved that one twice - first by reducing the limits
drastically, and then by making them be relative to the non-highmem memory
(rather than all of it).

So in effect, we actually reduced the limits more than originally
intended, although that particular effect should be noticeable mainly just
on 32-bit x86.

I'm certainly open to tuning. As long as "tuning" doesn't involve
something insane like dbench numbers.

Linus