diff options
author | Hristo Venev <hristo@venev.name> | 2023-10-17 23:40:52 +0300 |
---|---|---|
committer | Hristo Venev <hristo@venev.name> | 2023-10-24 21:10:16 +0300 |
commit | 01fabfa25f92424e35ecb4ae98e95a06aa2e278f (patch) | |
tree | 0b5c2d6711dd54556ad7ef3875b691aadf6ed0e3 /README.md | |
parent | 42d544a9c03aa4b682189f2274c5c1bea346d635 (diff) |
Improve backup consistency during snapshot
We now create the snapshot as "next" and only promote it to "current"
once it finishes. WAL files are linked to both current and next.
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -8,8 +8,6 @@ Data is stored in a local directory provided through the `PGBAK` environment var Some tasks are performed by a "sync" process that is automatically started in the background when necessary. This includes taking full snapshots and running the backup script. -Note that `pgbak` is not a full point-in-time recovery archiver. In some cases, for example during snapshots, some WAL files may be missed. - ## Backup directory structure - `$PGBAK/TIMESTAMP/` — One or more directories containing base backups and WAL segments. The `TIMESTAMP` is when the base backup was taken. @@ -38,6 +36,7 @@ When the `backup` script is started, the current directory is set to the subdire 1. the timestamp of the base backup 2. the current timestamp +3. an optional `old` flag if this is the last invocation of the backup script before switching to a newer snapshot Existing files will never disappear or change, provided the base backup timestamp is the same. However, new compressed WAL files may appear at any time. If this happens while the `backup` script is running, it will be called again with a refreshed current timestamp. |