Fix example archive_command for standalone backups so it doesn't return spurious...
authorAndrew Dunstan <[email protected]>
Sat, 15 Dec 2007 15:41:02 +0000 (15:41 +0000)
committerAndrew Dunstan <[email protected]>
Sat, 15 Dec 2007 15:41:02 +0000 (15:41 +0000)
doc/src/sgml/backup.sgml

index b7eab19950618a0a667d8d6f812df686a10299ce..e3ed4ccc85ff2fae9981e1834a2b0c180e75f8fa 100644 (file)
@@ -1257,7 +1257,7 @@ restore_command = 'copy /mnt/server/archivedir/%f "%p"'  # Windows
       To configure standalone backups you should use a switch file. If the
       file exists then archives are made, otherwise archiving is ignored.
 <programlisting>
-archive_command = 'test -f /var/lib/pgsql/backup_in_progress &amp;&amp; cp -i %p /var/lib/pgsql/archive/%f &lt;/dev/null'
+archive_command = 'if [ -f /var/lib/pgsql/backup_in_progress ]; then cp -i %p /var/lib/pgsql/archive/%f &lt;/dev/null ; fi'
 </programlisting>
       Backup can then be taken using a script like the following:
 <programlisting>