Re: PITR promote bug: Checkpointer writes to older timeline
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Michael Paquier <michael@paquier.xyz>
Cc: Andres Freund <andres@anarazel.de>,
Kyotaro Horiguchi <horikyota.ntt@gmail.com>,
masao.fujii@oss.nttdata.com, soumyadeep2007@gmail.com,
hlinnaka@iki.fi,
pgsql-hackers@postgresql.org, jyih@vmware.com, kyeap@vmware.com
Date: 2021-06-27T18:35:24Z
Lists: pgsql-hackers
Michael Paquier <michael@paquier.xyz> writes:
> I have been working on that over the last couple of days, and applied
> a fix down to 10. One thing that I did not like in the test was the
> use of compare() to check if the contents of the WAL segment before
> and after the timeline jump remained the same as this would have been
> unstable with any concurrent activity. Instead, I have added a phase
> at the end of the test with an extra checkpoint and recovery triggered
> once, which is enough to reproduce the PANIC reported at the top of
> the thread.
Buildfarm member hornet just reported a failure in this test:
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=hornet&dt=2021-06-27%2013%3A40%3A57
the critical bit being
2021-06-27 17:35:46.504 UTC [11862234:1] [unknown] LOG: connection received: host=[local]
2021-06-27 17:35:46.505 UTC [18350260:12] LOG: recovering prepared transaction 734 from shared memory
TRAP: FailedAssertion("TransactionIdPrecedesOrEquals(TransactionXmin, RecentXmin)", File: "procarray.c", Line: 2492, PID: 11862234)
2021-06-27 17:35:46.511 UTC [14876838:4] LOG: database system is ready to accept connections
It's not clear whether this is a problem with the test case or an
actual server bug, but I'm leaning to the latter theory. My gut
feel is it's some problem in the "snapshot scalability" work. It
doesn't look the same as the known open issue, but maybe related?
regards, tom lane
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Fix timeline assignment in checkpoints with 2PC transactions
- 1ec7162a8d34 10.17 landed
- f1d550f188e2 11.12 landed
- 4b1dd9b1ea75 12.7 landed
- 6e5ce888ad1e 13.3 landed
- 595b9cba2ab0 14.0 landed