Recovery using continuous archiving

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lucky29
    New Member
    • Aug 2013
    • 4

    Recovery using continuous archiving

    I have enabled streaming replication between two server say master and slave. Now after this I enabled archiving changing following parameters-

    On the master node, configure "postgresql.con f"

    archive_mode = on
    archive_command = 'cp %p /u01/arch/%f'
    archive_timeout = 120
    max_wal_senders = 5
    wal_keep_segmen ts = 10

    After this I edited the recovery.conf file on the slave server-

    modify "recovery.c onf" on the standby node

    trigger_file = '/tmp/pg_failover.tri gger'
    restore_command = 'cp /u01/arch/%f %p'

    Now due to server load the slave WAL receiver lags behind and the WAL needed by slave has been archived and removed from the pg_xlog.

    Issue is that the following error is generated on slave-
    cp: cannot stat `/u01/arch/000000010000000 5000000C5': No such file or directory
    2013-09-18 16:02:38 IST LOG: streaming replication successfully connected to primary
    2013-09-18 16:02:38 IST FATAL: could not receive data from WAL stream: FATAL: requested WAL segment 000000010000000 5000000C4 has already been removed

    Please help me to resolve this.

    Thanks in advance.
    Lucky
Working...