Re: Confusing comment in pg_upgrade in regards to VACUUM FREEZE - Mailing list pgsql-hackers

From Craig Ringer
Subject Re: Confusing comment in pg_upgrade in regards to VACUUM FREEZE
Date
Msg-id CAMsr+YEGNBaTJRDsuLVR08cFTTCzGYccVOhC8ht03qu5kbakVg@mail.gmail.com
Whole thread Raw
In response to Re: Confusing comment in pg_upgrade in regards to VACUUM FREEZE  (Alvaro Herrera <alvherre@2ndquadrant.com>)
List pgsql-hackers
On 18 April 2016 at 22:46, Alvaro Herrera <alvherre@2ndquadrant.com> wrote:
 
Nothing to do with that.  The VACUUM FREEZE is executed on the new
database before migrating the old data over; it's there so that the
existing data has no trace of any permanent "normal" Xids from the
original counter. 

Right. That makes sense, and explains why nobody's been screaming in horror as pg_upgrade takes six weeks to slowly freeze their tables ;)
 
The new cluster has rows created by initdb etc whose visibility information only makes sense in the context of the control state, clog, etc of the new cluster and we're about to clobber that. So they must be frozen.

Thanks. That feels very obvious in retrospect.

--
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: Re: Move PinBuffer and UnpinBuffer to atomics
Next
From: Robert Haas
Date:
Subject: Re: [BUGS] Breakage with VACUUM ANALYSE + partitions