pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kiriakos Tsourapas <ktsour@gmail.com>
To: Mark Kirkwood <mark.kirkwood@catalyst.net.nz>
Cc: pgsql-performance@postgresql.org
Subject: Re: Postgres becoming slow, only full vacuum fixes it
Date: Tue, 25 Sep 2012 14:07:55 +0300
Message-ID: <BA0641CA-5B57-4534-AB35-00B2A16FEA4B@gmail.com> (raw)
In-Reply-To: <5060E7F2.3010903@catalyst.net.nz>
References: <D15ECA12-8D6E-4E53-A294-5E175564CA61@gmail.com>
	<5060E7F2.3010903@catalyst.net.nz>

Hi Mark,

When the problem appears, vacuuming is not helping. I ran vacuum manually and the problem was still there. Only full vacuum worked.

As far as I have understood, autovacuuming is NOT doing FULL vacuum. So, messing around with its values should not help me in any way.


Thanks


> 
> Given that vacuum full fixes the issue I suspect you need to have autovacuum set wake up much sooner, not later. So autovacuum_naptime = 28800 or even = 60 (i.e the default) is possibly too long. We have several database here where I change this setting to 10 i.e:
> 
> autovacuum_naptime = 10s
> 
> 
> in order to avoid massive database bloat and queries that get slower and slower...
> 
> You might want to be a bit *less* aggressive with autovacuum_vacuum_scale_factor - I usually have this at 0.1, i.e:
> 
> autovacuum_vacuum_scale_factor = 0.1
> 
> 
> otherwise you will be vacuuming all the time - which is usually not what you want (not for all your tables anyway).
> 
> regards
> 
> Mark
> 
> 
> -- 
> Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-performance





view thread (24+ messages)  latest in thread

Message-ID: <BA0641CA-5B57-4534-AB35-00B2A16FEA4B@gmail.com>
Permalink:  ../BA0641CA-5B57-4534-AB35-00B2A16FEA4B@gmail.com/
Also on:    postgresql.org/message-id/BA0641CA-5B57-4534-AB35-00B2A16FEA4B@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: ktsour@gmail.com, mark.kirkwood@catalyst.net.nz
  Subject: Re: Postgres becoming slow, only full vacuum fixes it
  In-Reply-To: <BA0641CA-5B57-4534-AB35-00B2A16FEA4B@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox