mirror of
https://github.com/postgres/postgres.git
synced 2025-07-23 03:21:12 +03:00
Add info about using rsync to make base backups. Per report from
Jeff Frost, it may be necessary to ignore specific exit codes.
This commit is contained in:
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$PostgreSQL: pgsql/doc/src/sgml/backup.sgml,v 2.73 2005/10/22 22:09:49 tgl Exp $
|
$PostgreSQL: pgsql/doc/src/sgml/backup.sgml,v 2.74 2005/10/26 20:42:35 tgl Exp $
|
||||||
-->
|
-->
|
||||||
<chapter id="backup">
|
<chapter id="backup">
|
||||||
<title>Backup and Restore</title>
|
<title>Backup and Restore</title>
|
||||||
@ -677,12 +677,20 @@ SELECT pg_stop_backup();
|
|||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Some versions of GNU <application>tar</> consider it an error if a file
|
Some backup tools that you might wish to use emit warnings or errors
|
||||||
is changed while <application>tar</> is copying it. This case is normal,
|
if the files they are trying to copy change while the copy proceeds.
|
||||||
and not an error, when taking a base backup of an active database.
|
This situation is normal, and not an error, when taking a base backup of
|
||||||
Since ignoring all errors from <application>tar</> would be unwise,
|
an active database; so you need to ensure that you can distinguish
|
||||||
you should either manually inspect <application>tar</>'s messages or
|
complaints of this sort from real errors. For example, some versions
|
||||||
else use a different backup tool that does not complain about this case.
|
of <application>rsync</> return a separate exit code for <quote>vanished
|
||||||
|
source files</>, and you can write a driver script to accept this exit
|
||||||
|
code as a non-error case. Also,
|
||||||
|
some versions of GNU <application>tar</> consider it an error if a file
|
||||||
|
is changed while <application>tar</> is copying it. There does not seem
|
||||||
|
to be any very convenient way to distinguish this error from other types
|
||||||
|
of errors, other than manual inspection of <application>tar</>'s messages.
|
||||||
|
GNU <application>tar</> is therefore not the best tool for making base
|
||||||
|
backups.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
|
Reference in New Issue
Block a user