MultiXact bugs

From: Andres Freund <andres(at)2ndquadrant(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: MultiXact bugs
Date: 2013-11-24 00:02:03
Message-ID: 20131124000203.GA4403@alap2.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

The attached pgbench testcase can reproduce two issues:
1) (takes a bit)
TRAP: FailedAssertion("!(((xid) >= ((TransactionId) 3)))", File:/pruneheap.c", Line: 601)

That's because HeapTupleHeaderGetUpdateXid() ignores aborted updaters
and returns InvalidTransactionId in that case, but
HeapTupleSatisfiesVacuum() returns HEAPTUPLE_DELETE_IN_PROGRESS...

Looks like a 9.3+ issue, and shouldn't have a ll that high impact in
non-assert builds, page pruning will be delayed a bit.

2) we frequently error out in heap_lock_updated_tuple_rec() with
ERROR: unable to fetch updated version of tuple

That's because when we're following a ctid chain, it's perfectly
possible for the updated version of a tuple to already have been
vacuumed/pruned away if the the updating transaction has aborted.

Also looks like a 9.3+ issues to me, slightly higher impact, but in the
end you're just getting some errors under concurrency.

Greetings,

Andres Freund

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

Attachment Content-Type Size
mxact-init.sql text/plain 497 bytes
mxact-self.sql text/plain 202 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeremy Harris 2013-11-24 00:21:18 Re: Dynamic Shared Memory stuff
Previous Message Tom Lane 2013-11-23 23:06:03 Re: Re: Server is not getting started with log level as debug5 on master after commit 3147ac