Re: checkpoint spikes

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Greg Smith <greg(at)2ndquadrant(dot)com>
Cc: Janning <ml(at)planwerk6(dot)de>, pgsql-general(at)postgresql(dot)org
Subject: Re: checkpoint spikes
Date: 2010-06-11 19:48:54
Message-ID: 20100611194854.GA23114@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thu, Jun 10, 2010 at 04:00:54PM -0400, Greg Smith wrote:
>> 5. Does anybody know if I can set dirty_background_ratio to 0.5? As we
>> have 12 GB RAM and rather slow disks 0,5% would result in a maximum of
>> 61MB dirty pages.
>
> Nope. Linux has absolutely terrible controls for this critical
> performance parameter. The sort of multi-second spikes you're seeing
> are extremely common and very difficult to get rid of.

Another relevent parameter is /proc/sys/vm/dirty_writeback_centisecs.
By default linux only wakes up once every 5 seconds to check if there
is stuff to write out. I have found that reducing this tends to smooth
out bursty spikes. However, see:

http://www.westnet.com/~gsmith/content/linux-pdflush.htm

which indicates that kernel may try to defeat you here...

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patriotism is when love of your own people comes first; nationalism,
> when hate for people other than your own comes first.
> - Charles de Gaulle

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2010-06-11 20:18:20 Re: How to show the current schema or search path in the psql PROMP
Previous Message Adrian Klaver 2010-06-11 18:32:32 Re: How to show the current schema or search path in the psql PROMP