pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Simon Riggs <simon@2ndQuadrant.com>
To: Fujii Masao <masao.fujii@gmail.com>
Cc: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Guillaume Smet <guillaume.smet@gmail.com>
Cc: Peter Eisentraut <peter_e@gmx.net>
Cc: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: New trigger option of pg_standby
Date: Thu, 14 May 2009 20:10:04 +0100
Message-ID: <1242328204.3843.599.camel@ebony.2ndQuadrant> (raw)
In-Reply-To: <3f0b79eb0905141149lf5cef92j538f490c86dfedf8@mail.gmail.com>
References: <3f0b79eb0903242329j12865d55s348f5c873a956e71@mail.gmail.com>
	<49F01D79.8020805@enterprisedb.com>
	<3f0b79eb0904230515p751b5248n6ef96880617db055@mail.gmail.com>
	<4A095A39.3030100@enterprisedb.com>
	<3f0b79eb0905130127u3a3275b1w79f4d8cb729ded36@mail.gmail.com>
	<4A0A86D2.9080602@enterprisedb.com>
	<1985.1242234105@sss.pgh.pa.us>
	<4A0B10C7.2040309@enterprisedb.com>
	<1242247404.3843.503.camel@ebony.2ndQuadrant>
	<1242315415.3843.526.camel@ebony.2ndQuadrant>
	<3f0b79eb0905141149lf5cef92j538f490c86dfedf8@mail.gmail.com>


On Fri, 2009-05-15 at 03:49 +0900, Fujii Masao wrote:
> Hi,
> 
> On Fri, May 15, 2009 at 12:36 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> >
> > On Wed, 2009-05-13 at 21:43 +0100, Simon Riggs wrote:
> >> On Wed, 2009-05-13 at 21:26 +0300, Heikki Linnakangas wrote:
> >>
> >> > This whole thing can be considered to be a new feature.
> >>
> >> recovery.conf will contain a new optional parameter:
> >>
> >> recovery_end_command (string)
> >
> > Implemented.
> 
> > + 		ereport(signaled ? FATAL : WARNING,
> > + 				(errmsg("recovery_end_command \"%s\": return code %d",
> > + 								xlogRecoveryEndCmd, rc)));
> 
> In fast failover case, pg_standby has to delete the trigger file immediately
> if it's found. Otherwise, recovery may go wrong as I already described.
> http://archives.postgresql.org/pgsql-hackers/2009-04/msg01139.php
> 
> So, in fast mode, recovery_end_command would always fail to delete the
> trigger file, and cause warning. This is odd behavior, I think. We should
> change WARNING to DEBUG2 like RestoreArchivedFile() in the above code?

Using rm -f would avoid the WARNING.

I'd rather keep it at WARNING, since not sure what command I'll be
running and what a non-zero rc means.

-- 
 Simon Riggs           www.2ndQuadrant.com
 PostgreSQL Training, Services and Support




view thread (127+ messages)  latest in thread

Message-ID: <1242328204.3843.599.camel@ebony.2ndQuadrant>
Permalink:  ../1242328204.3843.599.camel@ebony.2ndQuadrant/
Also on:    postgresql.org/message-id/1242328204.3843.599.camel@ebony.2ndQuadrant

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: simon@2ndQuadrant.com, masao.fujii@gmail.com, heikki.linnakangas@enterprisedb.com, tgl@sss.pgh.pa.us, guillaume.smet@gmail.com, peter_e@gmx.net, Kevin.Grittner@wicourts.gov
  Subject: Re: New trigger option of pg_standby
  In-Reply-To: <1242328204.3843.599.camel@ebony.2ndQuadrant>

* 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