pg_basebackup: could not get transaction log end position from server: ERROR: requested WAL segment 0000000400002B9F000000B4 has already been removed
This attempted backup reached 430GB before failing.
We were advised on IRC to try -Xs, but that only works with a plain (uncompressed) backup, and as you'll note from above, we don't have enough disk space for this.
Is there anything else we can do apart from get a bigger disk (not trivial at the moment)? Any best practice?
I suspect that setting up WAL archiving and / or playing with the wal_keep_segments setting might help, but as you can probably gather, I'd like to be sure that I'm doing something sane before I dive in.