Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to figure out if wal archiving from a standby is possible and a viable option for a backup strategy on Postgresql 9.3.

The idea is to be able to take regular base backups and wal archives from a standby server in a remote DR site.

Unfortunately, the archive_command functionality is not available while the server is in standby_mode mode so I am wandering if the wal archiving could be done successfully using alternative ways like rsync, lsyncd etc.

Has anyone tried to this path can you share your experience?

share|improve this question

migrated from Apr 24 '14 at 9:59

This question came from our site for professional and enthusiast programmers.

For base backups just use pg_basebackup -X stream. No WAL archiving required. You can use the WAL archives from the master its self for your DR, no need to take separate archives from the standby. – Craig Ringer Apr 24 '14 at 1:28

Postgresql provides a pg_receivexlog utility that can be used instead of archive_command to do wal log archiving.

From the Doc: pg_receivexlog is used to stream transaction log from a running PostgreSQL cluster. The transaction log is streamed using the streaming replication protocol, and is written to a local directory of files. This directory can be used as the archive location for doing a restore using point-in-time recovery

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.