pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Josh Berkus <josh@agliodbs.com>
To: Joe Conway <mail@joeconway.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-performance <pgsql-performance@postgresql.org>
Subject: Re: rapid degradation after postmaster restart
Date: Sat, 13 Mar 2004 08:51:22 -0800
Message-ID: <200403130851.22684.josh@agliodbs.com> (raw)
In-Reply-To: <405330CD.4050304@joeconway.com>
References: <4052661D.5060505@joeconway.com>
	<18481.1079192379@sss.pgh.pa.us>
	<405330CD.4050304@joeconway.com>

Joe,

> IIRC, shared buffers was reasonable, maybe 128MB. One thing that is 
> worthy of note is that they are using pg_autovacuum and a very low 
> vacuum_mem setting (1024). But I also believe that max_fsm_relations and 
> max_fsm_pages have been bumped up from default (something like 10000 & 
> 200000).

pg_autovacuum may be your problem.   Imagine this:

1) The chain of updates and inserts called by the procedures makes enough 
changes, on its own, to trigger pg_autovacuum.
2) Because they have a big database, and a low vacuum_mem, a vacuum of the 
largest table takes noticable time, like several minutes.
3) This means that the vacuum is still running during the second and 
succeeding events ....

Something to check by watching the process list.

FWIW, I don't use pg_autovacuum for databases which have frequent large batch 
updates; I find it results in uneven performance.

Feel free to phone me if you're still stuck!

-- 
-Josh Berkus
 Aglio Database Solutions
 San Francisco




view thread (26+ messages)  latest in thread

Message-ID: <200403130851.22684.josh@agliodbs.com>
Permalink:  ../200403130851.22684.josh@agliodbs.com/
Also on:    postgresql.org/message-id/200403130851.22684.josh@agliodbs.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: josh@agliodbs.com, mail@joeconway.com, tgl@sss.pgh.pa.us
  Subject: Re: rapid degradation after postmaster restart
  In-Reply-To: <200403130851.22684.josh@agliodbs.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