Reputation: 51
I am setting up a PostgreSQL 9.3 standby server in Streaming replication.
I configured the recovery.conf
file with the archive_cleanup_command
. The WAL files shipped from the master to the temporary folder with the archive_command
are correctly saved, but are never deleted from the slave server.
I tried:
archive_cleanup_command = 'pg_archivecleanup /mnt/db1/incoming %r'
I also tried:
archive_cleanup_command = '/usr/pgsql-9.3/bin/pg_archivecleanup /mnt/db1_incoming_wals %r 2>>/tmp/archive_cleanup.log'
There is no entry in the log files (/var/log/postgres.log and /tmp/archive_cleanup.log)
What am I missing?
Upvotes: 2
Views: 4720
Reputation: 379
The questions asks "... when is called?". The answer is
This optional parameter specifies a shell command that will be executed at every restartpoint.
Upvotes: 2
Reputation: 151
Be sure to stop and restart your standby server. Reload does not seem to work. By the way, since it seems you wanted to have debug message dumped to /tmp/archive_cleanup.log, you might need the -d option as well.
Upvotes: 0