Re: pg_multixact not getting truncated

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Jim Nasby <Jim(dot)Nasby(at)bluetreble(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_multixact not getting truncated
Date: 2014-11-21 02:06:32
Message-ID: 546E9E28.3090107@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 11/20/2014 01:47 PM, Tom Lane wrote:
> Josh Berkus <josh(at)agliodbs(dot)com> writes:
>> Well, the first thing that comes to mind is that template0 should be
>> "permanently frozen". That is, all objects in it should be created with
>> frozen xid and mxids. After all, nobody can modify anything in it.
>
> That sounds about as unsafe as can be. You can't stop superusers from
> connecting to template0 and modifying it if they want to ... and I don't
> really want to say "ok, the consequence of that is silent disaster many
> moons later".

So it would get unfrozen when they modify it, and they'd have to deal
with it. Right now we're optimizing for something only 0.1% of users
ever do.

The harder part of this -- the handwavy part -- is the whole idea of a
"permanent freeze". Right now there's no way to mark anything as
"frozen until next modifed", we're just resetting the clock on it. If
there were any such thing, it would solve some of the problems around
vacuum freeze.

--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2014-11-21 03:58:59 Re: WAL format and API changes (9.5)
Previous Message Kouhei Kaigai 2014-11-21 01:53:03 Re: [v9.5] Custom Plan API