pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Stephen Frost <sfrost@snowman.net>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Mark Kirkwood <mark.kirkwood@catalyst.net.nz>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: Haribabu Kommi <kommi.haribabu@gmail.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: Per table autovacuum vacuum cost limit behaviour strange
Date: Thu, 2 Oct 2014 20:35:26 -0400
Message-ID: <20141003003526.GE28859@tamriel.snowman.net> (raw)
In-Reply-To: <20141002215950.GB5311@eldon.alvh.no-ip.org>
References: <CAA4eK1KDAUP=g59ku_0ekDoRjaGfEamyadQn5rJVt3j5oErLXg@mail.gmail.com>
	<53686F22.8030300@catalyst.net.nz>
	<20140826161911.GE6343@eldon.alvh.no-ip.org>
	<CA+Tgmoav37msTP0pVsrEYz4LBYU6SETMZGYTgPo5AEOC0yCMbA@mail.gmail.com>
	<20140930221644.GR5311@eldon.alvh.no-ip.org>
	<20141002135412.GX5311@eldon.alvh.no-ip.org>
	<CA+TgmobQokthgWmv1C9vjvpz=K9koovy6O+nWZ9rV8gwC8ioRw@mail.gmail.com>
	<20141002150336.GO28859@tamriel.snowman.net>
	<20141002153705.GY5311@eldon.alvh.no-ip.org>
	<20141002215950.GB5311@eldon.alvh.no-ip.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

* Alvaro Herrera (alvherre@2ndquadrant.com) wrote:
> Alvaro Herrera wrote:
> > Basically, if you are on 9.3.5 or earlier any per-table options for
> > autovacuum cost delay will misbehave (meaning: any such table will be
> > processed with settings flattened according to balancing of the standard
> > options, _not_ the configured ones).  If you are on 9.3.6 or newer they
> > will behave as described in the docs.
> 
> Another thing to note is that if you have configured a table to have
> cost_limit *less* than the default (say 150 instead of the default 200),
> the balance system will again break that and process the table at 200
> instead; in other words, the balancing system has completely broken the
> ability to tweak the cost system for individual tables in autovacuum.

That's certainly pretty ugly.

> With the v5 patch, the example tables above will be vacuumed at exactly
> 5000 and 150 instead.  The more complex patch I produced earlier would
> have them vacuumed at something like 4900 and 100 instead, so you
> wouldn't exceed the total of 5000.  I think there is some value to that
> idea, but it seems the complexity of managing this is too high.

Agreed.

> I am rather surprised that nobody has reported this problem before.  I
> am now of the mind that this is clearly a bug that should be fixed all
> the way back.

I'm coming around to that also, however, should we worry about users who
set per-table settings and then simply forgot about them?  I suppose
that won't matter too much unless the table is really active, and if it
is, they've probably already set it to zero.

	Thanks,

		Stephen

Attachments:

  [application/pgp-signature] signature.asc (818B, ../20141003003526.GE28859@tamriel.snowman.net/2-signature.asc)
  download

view thread (40+ messages)  latest in thread

Message-ID: <20141003003526.GE28859@tamriel.snowman.net>
Permalink:  ../20141003003526.GE28859@tamriel.snowman.net/
Also on:    postgresql.org/message-id/20141003003526.GE28859@tamriel.snowman.net

 · 

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-hackers@postgresql.org
  Cc: sfrost@snowman.net, alvherre@2ndquadrant.com, robertmhaas@gmail.com, mark.kirkwood@catalyst.net.nz, amit.kapila16@gmail.com, kommi.haribabu@gmail.com
  Subject: Re: Per table autovacuum vacuum cost limit behaviour strange
  In-Reply-To: <20141003003526.GE28859@tamriel.snowman.net>

* 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