Re: Slow query on a one-tuple table

MichaelDBA <[email protected]> Fri, 20 Sep 2019 09:09:35 -0400
Newsgroups gmane.comp.db.postgresql.performance
Message-ID <[email protected]>
Hi all,

I sometimes set autovacuum_vacuum_scale factor = 0 but only when I also 
set autovacuum_vacuum_threshold to some non-zero number to force vacuums 
after a certain number of rows are updated.  It takes the math out of it 
by setting the threshold explicitly.

But in this case he has also set autovacuum_vacuum_threshold to only 
25!  So I think you have to fix your settings by increasing one or both 
accordingly.

Regards,
Michael Vitale


Tom Lane wrote on 9/19/2019 6:57 PM:
> =?UTF-8?Q?Lu=c3=ads_Roberto_Weck?= <[email protected]> writes:
>> As fas as autovacuum options, this is what I'm using:
>> autovacuum_vacuum_scale_factor=0,
> Ugh ... maybe I'm misremembering, but I *think* that has the effect
> of disabling autovac completely.  You don't want zero.
>
> Check in pg_stat_all_tables.last_autovacuum to see if anything
> is happening.  If the dates seem reasonably current, then I'm wrong.
>
> 			regards, tom lane
>
>