pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mark Steben <msteben@autorevenue.com>
To: 'Tom Lane' <tgl@sss.pgh.pa.us>
Cc: pgsql-admin@postgresql.org
Subject: Re: question on warm standby
Date: Fri, 14 Nov 2008 13:25:20 -0500
Message-ID: <0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534> (raw)
In-Reply-To: <16779.1226631948@sss.pgh.pa.us>
References: <77785C387FC44102BF108D152DC501C2@dei26g028534>
	<16779.1226631948@sss.pgh.pa.us>



 
 
-----Original Message-----
From: Tom Lane [mailto:tgl@sss.pgh.pa.us] 
Sent: Thursday, November 13, 2008 10:06 PM
To: Mark Steben
Cc: pgsql-admin@postgresql.org
Subject: Re: [ADMIN] question on warm standby 

"Mark Steben" <msteben@autorevenue.com> writes:
> I am running postgres 8.3.4 on master(mymachine) and slave(hummer).  I am
> attempting to implement warm standby.
>   1.  On mymachine I have the following archive_command:
>       Scp %p postgres@hummer:/var/backups/archlog/%f
>           (scp has been set up with ssh keys so that password
>                Is not required for postgres user)
>     This works fine.  Copies wal logs to the /var/backups/archlog
directory.

Okay ...

>   2. Before I attempt pg_standby or some other wait script on hummer I
have
>       Used a simple cp command in my recovery.conf file to manually
restore
>        My first set of updates:

>      restore_command = 'cp /var/backups/archlog/%f  %p'

This looks fine too, perfectly standard.
 
>        From the doc I am assuming that %f should be the file name(s) of
the
>         Wal log in /var/backups/archlog/ to be copied into the   
>          /*/*/*/*/pg_xlog directory referenced by %p
>         But %f seems to be referencing current wal log names in 
>          /*/*/*/*/pg_xlog.  I am getting messages like:
      
> cp: cannot stat `/var/backups/archlog/0000000600000003000000D2': 
>       No such file or directory

Are you sure that's an error?  As per the docs, the restore_command will
sometimes be asked for files that aren't there.  I'd expect one or two
such failures in a restore session.

>       0000000600000003000000D2 is an actual wal log in hummer's
>        /*/*/*/*/pg_xlog directory.

Yeah, but is it in hummer's /var/backups/archlog ?

[Mark Steben] No it's not. But there are wal logs in there 
Copied successfully from the master that I expected to be
Applied to the database and were not

			regards, tom lane




view thread (4+ messages)  latest in thread

Message-ID: <0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534>
Permalink:  ../0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534/
Also on:    postgresql.org/message-id/0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: msteben@autorevenue.com, tgl@sss.pgh.pa.us
  Subject: Re: question on warm standby
  In-Reply-To: <0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534>
  References: <77785C387FC44102BF108D152DC501C2@dei26g028534> <16779.1226631948@sss.pgh.pa.us> <0CB772EF23F44ED393EE5AB5F1BC0FF0@dei26g028534>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox