diff options
author | Robert Haas <rhaas@postgresql.org> | 2024-03-13 15:04:22 -0400 |
---|---|---|
committer | Robert Haas <rhaas@postgresql.org> | 2024-03-13 15:12:33 -0400 |
commit | 2041bc4276c95ac014510032e622a4baf70b29f1 (patch) | |
tree | 7fb89a55324b84f867d8cc1a1f83f3541c1ad484 /doc/src | |
parent | 1ee910ce437188eab40eddf32dc7d81952e99f82 (diff) | |
download | postgresql-2041bc4276c95ac014510032e622a4baf70b29f1.tar.gz postgresql-2041bc4276c95ac014510032e622a4baf70b29f1.zip |
Add the system identifier to backup manifests.
Before this patch, if you took a full backup on server A and then
tried to use the backup manifest to take an incremental backup on
server B, it wouldn't know that the manifest was from a different
server and so the incremental backup operation could potentially
complete without error. When you later tried to run pg_combinebackup,
you'd find out that your incremental backup was and always had been
invalid. That's poor timing, because nobody likes finding out about
backup problems only at restore time.
With this patch, you'll get an error when trying to take the (invalid)
incremental backup, which seems a lot nicer.
Amul Sul, revised by me. Review by Michael Paquier.
Discussion: http://postgr.es/m/CA+TgmoYLZzbSAMM3cAjV4Y+iCRZn-bR9H2+Mdz7NdaJFU1Zb5w@mail.gmail.com
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/backup-manifest.sgml | 17 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_verifybackup.sgml | 7 |
2 files changed, 20 insertions, 4 deletions
diff --git a/doc/src/sgml/backup-manifest.sgml b/doc/src/sgml/backup-manifest.sgml index 771be1310a1..d5ec244834e 100644 --- a/doc/src/sgml/backup-manifest.sgml +++ b/doc/src/sgml/backup-manifest.sgml @@ -37,7 +37,22 @@ <term><literal>PostgreSQL-Backup-Manifest-Version</literal></term> <listitem> <para> - The associated value is always the integer 1. + The associated value is an integer. Beginning in + <productname>PostgreSQL</productname> <literal>17</literal>, + it is <literal>2</literal>; in older versions, it is <literal>1</literal>. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><literal>System-Identifier</literal></term> + <listitem> + <para> + The database system identifier of the + <productname>PostgreSQL</productname> instance where the backup was + taken. This field is present only when + <literal>PostgreSQL-Backup-Manifest-Version</literal> is + <literal>2</literal>. </para> </listitem> </varlistentry> diff --git a/doc/src/sgml/ref/pg_verifybackup.sgml b/doc/src/sgml/ref/pg_verifybackup.sgml index 36335e0a188..a3f167f9f6e 100644 --- a/doc/src/sgml/ref/pg_verifybackup.sgml +++ b/doc/src/sgml/ref/pg_verifybackup.sgml @@ -53,9 +53,10 @@ PostgreSQL documentation Backup verification proceeds in four stages. First, <literal>pg_verifybackup</literal> reads the <literal>backup_manifest</literal> file. If that file - does not exist, cannot be read, is malformed, or fails verification - against its own internal checksum, <literal>pg_verifybackup</literal> - will terminate with a fatal error. + does not exist, cannot be read, is malformed, fails to match the system + identifier with <filename>pg_control</filename> of the backup directory or + fails verification against its own internal checksum, + <literal>pg_verifybackup</literal> will terminate with a fatal error. </para> <para> |