forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit05e2293
committed
Fix possible pg_basebackup failure on standby with "include WAL".
If a restartpoint flushed no dirty buffers, it could fail to updatethe minimum recovery point, leading to a minimum recovery point priorto the starting REDO location. perform_base_backup() would interpretthat as meaning that no WAL files at all needed to be included in thebackup, failing an internal sanity check. To fix, have restartpointsalways update the minimum recovery point to just after the checkpointrecord itself, so that the file (or files) containing the checkpointrecord will always be included in the backup.Code by Amit Kapila, per a design suggestion by me, with someadditional work on the code comment by me. Test case by MichaelPaquier. Report by Kyotaro Horiguchi.1 parent445035a commit05e2293
File tree
2 files changed
+33
-1
lines changed- src
- backend/access/transam
- test/recovery/t
2 files changed
+33
-1
lines changedLines changed: 28 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
612 | 612 |
| |
613 | 613 |
| |
614 | 614 |
| |
615 |
| - | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
616 | 618 |
| |
617 | 619 |
| |
618 | 620 |
| |
619 | 621 |
| |
| 622 | + | |
620 | 623 |
| |
621 | 624 |
| |
622 | 625 |
| |
| |||
8691 | 8694 |
| |
8692 | 8695 |
| |
8693 | 8696 |
| |
| 8697 | + | |
8694 | 8698 |
| |
8695 | 8699 |
| |
8696 | 8700 |
| |
| |||
8710 | 8714 |
| |
8711 | 8715 |
| |
8712 | 8716 |
| |
| 8717 | + | |
8713 | 8718 |
| |
8714 | 8719 |
| |
8715 | 8720 |
| |
| |||
8723 | 8728 |
| |
8724 | 8729 |
| |
8725 | 8730 |
| |
| 8731 | + | |
8726 | 8732 |
| |
8727 | 8733 |
| |
8728 | 8734 |
| |
| |||
8826 | 8832 |
| |
8827 | 8833 |
| |
8828 | 8834 |
| |
| 8835 | + | |
| 8836 | + | |
| 8837 | + | |
| 8838 | + | |
| 8839 | + | |
| 8840 | + | |
| 8841 | + | |
| 8842 | + | |
| 8843 | + | |
| 8844 | + | |
| 8845 | + | |
| 8846 | + | |
| 8847 | + | |
| 8848 | + | |
| 8849 | + | |
| 8850 | + | |
| 8851 | + | |
| 8852 | + | |
| 8853 | + | |
| 8854 | + | |
| 8855 | + | |
8829 | 8856 |
| |
8830 | 8857 |
| |
8831 | 8858 |
| |
|
Lines changed: 5 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
24 | 24 |
| |
25 | 25 |
| |
26 | 26 |
| |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
27 | 32 |
| |
28 | 33 |
| |
29 | 34 |
| |
|
0 commit comments
Comments
(0)