pgsql: amcheck: Distinguish interrupted page deletion from corruption. - Mailing list pgsql-committers

From Noah Misch
Subject pgsql: amcheck: Distinguish interrupted page deletion from corruption.
Date
Msg-id E1qxa6G-003AIm-QY@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
amcheck: Distinguish interrupted page deletion from corruption.

This prevents false-positive reports about "the first child of leftmost
target page is not leftmost of its level", "block %u is not leftmost"
and "left link/right link pair".  They appeared if amcheck ran before
VACUUM cleaned things, after a cluster exited recovery between the
first-stage and second-stage WAL records of a deletion.  Back-patch to
v11 (all supported versions).

Reviewed by Peter Geoghegan.

Discussion: https://postgr.es/m/20231005025232.c7.nmisch@google.com

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/42496cba60bc086f3fdba4b3d20426e27100fbfb

Modified Files
--------------
contrib/amcheck/t/005_pitr.pl   | 89 +++++++++++++++++++++++++++++++++++++++++
contrib/amcheck/verify_nbtree.c | 83 ++++++++++++++++++++++++++++++++++++--
2 files changed, 168 insertions(+), 4 deletions(-)


pgsql-committers by date:

Previous
From: Bruce Momjian
Date:
Subject: pgsql: pgindent run to fix commits de64268561 and 5ae2087202a
Next
From: Michael Paquier
Date:
Subject: Re: pgsql: Teach contrib/amcheck to check the unique constraint violation