Re: pg_upgrade and materialized views

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Claudio Freire <klaussfreire(at)gmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: pg_upgrade and materialized views
Date: 2018-02-20 21:27:44
Message-ID: 23575.1519162064@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Claudio Freire <klaussfreire(at)gmail(dot)com> writes:
> I'm not 100% sure this is a pg_upgrade bug or a pg_dump
> --binary-upgrade one, or some other thing, but at this point I'm
> fairly certain there's something wrong in one of them.

The symptoms you're mentioning suggest two bugs: (1) it's not clear
why binary upgrade should treat a matview's relfrozenxid differently
from a regular table's; (2) independently of that, it sounds like REFRESH
MATERIALIZED VIEW CONCURRENTLY is somehow preventing advancement of the
matview's relfrozenxid in the source DB.

> I just tried to pg_upgrade a database from 9.5 to 10.2. I took a
> snapshot off a replica, promoted it, and then did the pg_upgrade there
> (to avoid breaking our production server).

And that brings replication behavior into the mix, too :-(. I'd
suggest seeing if you can duplicate these problems without any
replication involved.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Andres Freund 2018-02-20 21:32:46 Re: pg_upgrade and materialized views
Previous Message Alvaro Herrera 2018-02-20 21:26:59 Re: pg_upgrade and materialized views