BUG #3877: Doc Clarification: archive_command and restore_command replacements

From: "Kevin Hunt" <kevin(at)centropy(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #3877: Doc Clarification: archive_command and restore_command replacements
Date: 2008-01-15 19:12:17
Message-ID: 200801151912.m0FJCHBV019540@wwwmaster.postgresql.org
Views: Raw Message | Whole Thread | Download mbox
Thread:
Lists: pgsql-bugs


The following bug has been logged online:

Bug reference: 3877
Logged by: Kevin Hunt
Email address: kevin(at)centropy(dot)com
PostgreSQL version: 8.2.6
Operating system: n/a
Description: Doc Clarification: archive_command and restore_command
replacements
Details:

When describing archive_command and restore_command (Chapter 23 - Backup and
Restore), the replacement strings '%p' and '%f' are explained:

"In this string, any %p is replaced by the path name of the file to archive,
while any %f is replaced by the file name only."

The description of %p is misleading since it is replaced with not just the
path, but also filename. The way it is written now, one might expect the
string "%p/%f" to resolve to the full path and filename of the file.
However, "%p" is sufficient.

A small change in the sentence would clarify:
"In this string, any %p is replaced by the full path and file name of the
file to archive, while any %f is replaced by the file name only."

An example showing how the sample commands would be expanded would also
help:

---
The simplest useful command is something like
archive_command = 'cp -i %p /mnt/server/archivedir/%f </dev/null'

The above example might be expanded to
cp -i /var/lib/postgresql/8.2/main/pgdata/pg_xlog/00000001000000A900000065
/mnt/server/archivedir/00000001000000A900000065 </dev/null

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message J6M 2008-01-15 19:21:35 Re: BUG #3876: Problems migrating databases
Previous Message Ruben Camargo Gomez 2008-01-15 16:52:13 BUG #3876: Problems migrating databases