Re: Autovacuum vs statement_timeout

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org, Bruce Momjian <bruce(at)momjian(dot)us>, Greg Sabino Mullane <greg(at)turnstep(dot)com>
Subject: Re: Autovacuum vs statement_timeout
Date: 2008-03-15 01:44:39
Message-ID: 13531.1205545479@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Tom Lane wrote:
>> To me, the killer reason for statement_timeout = 0 during pg_dump
>> is that without it, routine cron-driven dumps could fail, and the
>> user might not notice until he really really needed that dump.

> This concrete case if of course valid, but if you take a step back,
> there are about half a dozen ways to configure the server to make
> pg_dump fail.

Sure, but I think in a lot of situations there is a use-case for
a nonzero default statement_timeout, so it seems to me worthwhile
to protect pg_dump from that rather than let DBAs find out the
hard way. Also, statement_timeout is particularly nasty in that
you may not see any failure when you first set up and test your
dump strategy. It'll get you after your tables have grown, or
on a day when there's particularly heavy activity concurrent
with the dump.

> # DON'T SET THIS PARAMETER IN THE CONFIGURATION FILE OR YOUR BACKUPS WILL FAIL

If there are any parameters for which that is actually appropriate,
wouldn't it be *more* appropriate to flat-out prevent them from
being set from the config file? I believe we have a GUC variable
flag already for things that shouldn't be in the file, but it's
not enforced.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2008-03-15 01:58:46 Re: Commit fest?
Previous Message Joshua D. Drake 2008-03-15 01:44:22 Re: Commit fest?