9.0 Replication and archive cleanup

Поиск
Список
Период
Сортировка
От Kyle R. Burton
Тема 9.0 Replication and archive cleanup
Дата
Msg-id CANP+8rmHJ2Sg=WwBqZAzr604ecPpoq-Md40U+Q6PhZum0q=_kw@mail.gmail.com
обсуждение исходный текст
Список pgsql-admin
I have a master and slave set up with replication - both xlog and
streaming replication are set up and working great.  The slave keeps
up with the master and is available for read-only queries.

I just configured the archive_cleanup_command in my recovery.conf file
on the slave to use pg_archivecleanup, and restarted the slave.  After
doing so, and confirming that at least 1 new xlog was shipped to the
slave, I am not seeing any evidence of the archivecleanup command
being run.  No files are removed, nor is there anything in the slave's
postgres log output regarding archive cleanup.

This is my recovery.conf:

    standby_mode = 'on'
    primary_conninfo = 'host=<<master-ip-addr>> port=5432
user=<<user>> password=<<pass>>'
    restore_command = 'cp /var/lib/postgresql/replication/db1/wal/%f %p'
    trigger_file = '/var/lib/postgresql/become-master'
    archive_cleanup_command =
'/usr/lib/postgresql/9.0/bin/pg_archivecleanup
/var/lib/postgresql/replication/db1/wal %r'

I am not sure if I have mis-configured things or if I'm not
understanding the relationship between the xlog shipping and streaming
replication.

Is the xlog recovery (and cleanup) not triggered when streaming
replication is enabled?  If that's the case, what is a good strategy
for cleaning these up?


Regards,

Kyle

--
Twitter: @kyleburton
Blog: http://asymmetrical-view.com/
Fun: http://snapclean.me/

В списке pgsql-admin по дате отправления:

Предыдущее
От: "Kevin Grittner"
Дата:
Сообщение: Re: WAL archiving to two locations in warm standby
Следующее
От: Mario Splivalo
Дата:
Сообщение: Replicating privileges from one user to another