forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit2a0bfa4
committed
Prevent WAL files created by pg_basebackup -x/X from being archived again.
WAL (and timeline history) files created by pg_basebackup did notmaintain the new base backup's archive status. That's currently not aproblem if the new node is used as a standby - but if that node ispromoted all still existing files can get archived again. With a highwal_keep_segment settings that can happen a significant time later -which is quite confusing.Change both the backend (for the -x/-X fetch case) and pg_basebackup(for -X stream) itself to always mark WAL/timeline files included inthe base backup as .done. That's in line with walreceiver.c doing so.The verbosity of the pg_basebackup changes show pretty clearly that itneeds some refactoring, but that'd result in not be backpatchablechanges.Backpatch to 9.1 where pg_basebackup was introduced.Discussion: 20141205002854.GE21964@awork2.anarazel.de1 parent6dd3050 commit2a0bfa4
1 file changed
+20
-0
lines changedLines changed: 20 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
257 | 257 |
| |
258 | 258 |
| |
259 | 259 |
| |
| 260 | + | |
260 | 261 |
| |
| 262 | + | |
261 | 263 |
| |
262 | 264 |
| |
263 | 265 |
| |
| |||
290 | 292 |
| |
291 | 293 |
| |
292 | 294 |
| |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
293 | 304 |
| |
294 | 305 |
| |
295 | 306 |
| |
| |||
715 | 726 |
| |
716 | 727 |
| |
717 | 728 |
| |
| 729 | + | |
| 730 | + | |
| 731 | + | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
718 | 738 |
| |
719 | 739 |
| |
720 | 740 |
| |
|
0 commit comments
Comments
(0)