postgresql/contrib/amcheck
Peter Geoghegan 6754fe65a4 amcheck: Skip unlogged relations during recovery.
contrib/amcheck failed to consider the possibility that unlogged
relations will not have any main relation fork files when running in hot
standby mode.  This led to low-level "can't happen" errors that complain
about the absence of a relfilenode file.

To fix, simply skip verification of unlogged index relations during
recovery.  In passing, add a direct check for the presence of a main
fork just before verification proper begins, so that we cleanly verify
the presence of the main relation fork file.

Author: Andrey Borodin, Peter Geoghegan
Reported-By: Andrey Borodin
Diagnosed-By: Andrey Borodin
Discussion: https://postgr.es/m/DA9B33AC-53CB-4643-96D4-7A0BBC037FA1@yandex-team.ru
Backpatch: 10-, where amcheck was introduced.
2019-08-12 15:21:32 -07:00
..
expected Follow the rule that regression-test-created roles are named "regress_xxx". 2019-06-25 23:06:17 -04:00
sql Follow the rule that regression-test-created roles are named "regress_xxx". 2019-06-25 23:06:17 -04:00
.gitignore Add .gitignore to contrib/amcheck. 2017-03-09 22:45:24 -05:00
Makefile Allow amcheck to re-find tuples using new search. 2019-03-20 10:41:36 -07:00
amcheck--1.0--1.1.sql Add amcheck verification of heap relations belonging to btree indexes. 2018-03-31 19:52:01 -07:00
amcheck--1.0.sql
amcheck--1.1--1.2.sql Allow amcheck to re-find tuples using new search. 2019-03-20 10:41:36 -07:00
amcheck.control Allow amcheck to re-find tuples using new search. 2019-03-20 10:41:36 -07:00
verify_nbtree.c amcheck: Skip unlogged relations during recovery. 2019-08-12 15:21:32 -07:00