Re: Help with PITR in PostgreSQL 8.4 - Mailing list pgsql-admin

From Nestor A. Diaz
Subject Re: Help with PITR in PostgreSQL 8.4
Date
Msg-id 51E6BBF6.2000000@tiendalinux.com
Whole thread Raw
In response to Help with PITR in PostgreSQL 8.4  ("Nestor A. Diaz" <nestor@tiendalinux.com>)
Responses Re: Help with PITR in PostgreSQL 8.4  ("Gilberto Castillo" <gilberto.castillo@etecsa.cu>)
List pgsql-admin


On 07/17/2013 03:05 AM, chiru r wrote:
Hi Nestor,

So the question is: Can I have some continues wal archiving and then
transfer all WAL files to *standby* everyday, recover the database and
backup all data without having to rsync the data every time i make a
backup ?

Yes,You can do as you mentioned.

1) set the below parameters in Postgresql.conf file on Primary server.

  archive_mode=on
archive_command='cp %p  /opt/backup/wal_archives/%f'

2)apply these wall files to standby server hourly/daily basis as your requirement.
   configure the recovery.conf file.
Hi Chiru, I have done archiving on primary server, and recovery on standby server, howerver, after the first recovery I am unable to recover more wal files on standby server

Can it be possible in 8.4 ? or just in 9.1 ?

This is the recovery I use:

<< EOF
restore_command = '/usr/lib/postgresql/8.4/bin/pg_standby -l -d -s 2 -t /var/run/postgresql/8.4-main.trigger /var/lib/postgresql/8.4/main/wal-archive %f %p %r 2>>/var/log/postgresql/postgresql-8.4-main-standby.log'
recovery_end_command = 'rm -f /var/run/postgresql/8.4-main.trigger'

EOF

Slds.

  
Best Regards,
Chiru



-- 
Typed on my key64.org keyboard

Nestor A Diaz

pgsql-admin by date:

Previous
From: Javier Urbano Contreras
Date:
Subject: comparison schema/data
Next
From: "Gilberto Castillo"
Date:
Subject: Re: Help with PITR in PostgreSQL 8.4