1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-14 10:13:05 +02:00
pgbackrest/test
David Steele 5ed6f8df14
Fix spurious automatic delta backup on backup from standby.
When performing backup from standby the file sizes on the standby may not be equal to file sizes on the primary. This is because replication continues during the backup and by the time the file is copied from the standby it may have changed. Since we cap the size of all files copied from the standby this practically applies to truncation and in particular truncation of free space maps (at least, every case we have seen so far is an fsm). Free space maps are especially vulnerable since they are only partially replicated, which amplifies the difference between the primary and standby.

On an incremental backup it may look like the size has changed on the primary (because of the final size recorded by the standby in the prior backup) but the timestamp may not have changed on the primary and this will trigger a checksum delta for safety. While this has no impact on backup integrity, checksum delta incrementals can run much longer than regular incrementals and backup schedules may be impacted.

The solution is to preserve the original size in the manifest and use it to do the time/size check. In the case of backup from standby the original size will always be the size on the primary, which makes comparisons against subsequent file sizes on the primary consistent. Original size is only stored in the manifest when it differs from final size, so there should not be any noticeable manifest bloat.
2023-07-18 07:35:12 +02:00
..
certificate SFTP support for repository storage. 2023-05-13 19:16:16 +03:00
code-count v2.46: Block Incremental Backup and SFTP Storage 2023-05-22 11:13:13 +03:00
data Automate generation of WAL and pg_control test files. 2017-11-18 20:02:54 -05:00
lib/pgBackRestTest Remove unresolved todo from 87087fac. 2023-06-29 11:08:58 +02:00
src Fix spurious automatic delta backup on backup from standby. 2023-07-18 07:35:12 +02:00
.gitignore Move coverage results to test/result. 2020-03-14 15:29:42 -04:00
ci.pl Remove user-facing documentation references to --vm=none. 2023-05-23 10:58:51 +03:00
container.yaml Update Fedora test image to Fedora 38. 2023-06-22 18:23:06 +02:00
define.yaml Improve performance of SFTP storage driver. 2023-07-07 10:36:15 +02:00
Dockerfile SFTP support for repository storage. 2023-05-13 19:16:16 +03:00
test.pl Remove double spaces from comments and documentation. 2023-05-02 12:57:12 +03:00
uncrustify.cfg Check for stray execute permissions in test.pl --code-format. 2023-02-01 12:57:04 +07:00
Vagrantfile SFTP support for repository storage. 2023-05-13 19:16:16 +03:00