Skip site navigation (1) Skip section navigation (2)

Re: Problem with 8.4 stats collector high load

From: Jakub Ouhrabka <kuba(at)comgate(dot)cz>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Problem with 8.4 stats collector high load
Date: 2010-02-17 07:33:56
Message-ID: 4B7B9BE4.4030907@comgate.cz (view raw or flat)
Thread:
Lists: pgsql-hackers
 > well, my current opinion is that we should spend some nonzero amount
 > of thought into figuring out what to do.

I'd suggest to do it like this:

Do autovac_refresh_stats() once per autovacuum_naptime/2 and share the 
result among all autovacuum workers.

This would guarantee that autovacuum is fired no later than 
autovacuum_naptime after the condition for the run became true.

If it's not that easy to code then don't share it among the workers and 
do it once per worker - typically there are not so many workers.

And for bigger installations document that it's highly recommend to put 
the stats file on ramdisk.

Kuba

Dne 17.2.2010 0:12, Alvaro Herrera napsal(a):
> Tom Lane wrote:
>> Alvaro Herrera<alvherre(at)commandprompt(dot)com>  writes:
>>> Jakub Ouhrabka wrote:
>>>> Was autovacuum requesting to write this 20MB file 650x per minute?
>>
>>> Yes, exactly.
>>
>>> Ideally, autovacuum would only request a new copy of the file if the one
>>> it got was considerably out of date.  Obviously a tenth of a second is
>>> not old enough.
>>
>> Wasn't it you that insisted on a short staleness criterion for autovac
>> in the first place?
>
> well, my current opinion is that we should spend some nonzero amount of
> thought into figuring out what to do.
>

In response to

Responses

pgsql-hackers by date

Next:From: Jakub OuhrabkaDate: 2010-02-17 07:42:05
Subject: Re: Problem with 8.4 stats collector high load
Previous:From: Matthias BrantnerDate: 2010-02-17 07:23:45
Subject: Re: XQuery support

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group