Re: pg_upgrade bug found!

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: Jeff Davis <pgsql(at)j-davis(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, RhodiumToad on IRC <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
Subject: Re: pg_upgrade bug found!
Date: 2011-04-07 21:47:00
Message-ID: 201104072147.p37Ll0500602@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Kevin Grittner wrote:
> Bruce Momjian <bruce(at)momjian(dot)us> wrote:
>
> > all we need to do is set those hint bits before the clog gets
> > remove, so maybe just a SELECT * would do the trick!
>
> Does that mean that those experiencing the problem are failing to do
> the vacuumdb run which is recommended in the pg_upgrade instructions?

You know, I looked at that, but I don't think that is going to save me.
:-( It says:

Upgrade complete
----------------
| Optimizer statistics are not transferred by pg_upgrade
| so consider running:
| vacuumdb --all --analyze-only
| on the newly-upgraded cluster.

| Running this script will delete the old cluster's data files:
| /usr/var/local/pgdev/pgfoundry/pg_migrator/pg_migrator/delete_old_cluster.sh

We recommend 'vacuumdb --all --analyze-only' which I assume only samples
random pages and does not set all the hint bits. In fact, you can't
even analyze TOAST tables:

test=> ANALYZE pg_toast.pg_toast_3596;
WARNING: skipping "pg_toast_3596" --- cannot analyze non-tables or
special system tables
ANALYZE

but you can SELECT from them:

chunk_id | chunk_seq | chunk_data
----------+-----------+------------
(0 rows)

Also, if we force VACUUM FREEZE on the toast tables we would have no
need to advance their relfrozenxids because all the xids would be fixed.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ It's impossible for everything to be true. +

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Davis 2011-04-07 21:48:58 Re: pg_upgrade bug found!
Previous Message Kevin Grittner 2011-04-07 21:38:13 Re: pg_upgrade bug found!