Add prefix checks in exclude lists for pg_rewind, pg_checksums and base backups
Michael Paquier <michael@paquier.xyz>
Add prefix checks in exclude lists for pg_rewind, pg_checksums and base backups An instance of PostgreSQL crashing with a bad timing could leave behind temporary pg_internal.init files, potentially causing failures when verifying checksums. As the same exclusion lists are used between pg_rewind, pg_checksums and basebackup.c, all those tools are extended with prefix checks to keep everything in sync, with dedicated checks added for pg_internal.init. Backpatch down to 11, where pg_checksums (pg_verify_checksums in 11) and checksum verification for base backups have been introduced. Reported-by: Michael Banck Author: Michael Paquier Reviewed-by: Kyotaro Horiguchi, David Steele Discussion: https://postgr.es/m/62031974fd8e941dd8351fbc8c7eff60d59c5338.camel@credativ.de Backpatch-through: 11
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/replication/basebackup.c | modified | +50 −25 |
| src/bin/pg_basebackup/t/010_pg_basebackup.pl | modified | +4 −4 |
| src/bin/pg_rewind/filemap.c | modified | +31 −12 |
| src/bin/pg_verify_checksums/pg_verify_checksums.c | modified | +28 −11 |
Discussion
- [Patch] Make pg_checksums skip foreign tablespace directories 26 messages · 2020-01-30 → 2020-02-27