Re: pg_upgrade < 9.3 -> >=9.3 misses a step around multixacts

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Bruce Momjian <bruce(at)momjian(dot)us>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, PostgreSQL Bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: pg_upgrade < 9.3 -> >=9.3 misses a step around multixacts
Date: 2014-07-20 23:37:15
Message-ID: 19458.1405899435@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> On 2014-07-20 19:11:40 -0400, Tom Lane wrote:
>> I wonder whether we should change vac_update_relstats so that it only
>> applies the "relminxid mustn't go backwards" rule as long as relminxid
>> is sane, ie, not in the future. If it is in the future, forcibly update
>> it to the cutoff we actually used. Likewise for relminmxid. And I guess
>> we'd need a similar rule for updating datmin(m)xid.

> I'm wondering the same. How would we do that from a concurreny POV for
> the pg_database rows? I think we could just accept the race condition
> that two xacts move dbform->datminmxid backwards to different values
> since both have to be 'somewhat' correct?

Seems no worse than it is today. Is it even possible for two xacts to be
trying to update that at the same time?

> I think this is out of the remit for 9.3.5. At least I don't have the
> mental capacity to do this properly till tomorrow afternoon.

Doesn't sound that hard to me (and I'm still reasonably awake, which
I bet you're not). Will take a look.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Andres Freund 2014-07-20 23:49:25 Re: pg_upgrade < 9.3 -> >=9.3 misses a step around multixacts
Previous Message Andres Freund 2014-07-20 23:31:25 Re: pg_upgrade < 9.3 -> >=9.3 misses a step around multixacts