Re: Hot standby, recovery infra - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: Hot standby, recovery infra
Date
Msg-id 4981E554.9030907@enterprisedb.com
Whole thread Raw
In response to Re: Hot standby, recovery infra  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Responses Re: Hot standby, recovery infra  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-hackers
Heikki Linnakangas wrote:
> It looks like if you issue a fast shutdown during recovery, postmaster 
> doesn't kill bgwriter.

Hmm, seems like we haven't thought through how shutdown during 
consistent recovery is supposed to behave in general. Right now, smart 
shutdown doesn't do anything during consistent recovery, because the 
startup process will just keep going. And fast shutdown will simply 
ExitPostmaster(1), which is clearly not right.

I'm thinking that in both smart and fast shutdown, the startup process 
should exit in a controlled way as soon as it's finished with the 
current WAL record, and set minSafeStartPoint to the current point in 
the replay.

I wonder if bgwriter should perform a restartpoint before exiting? 
You'll have to start with recovery on the next startup anyway, but at 
least we could minimize the amount of WAL that needs to be replayed.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: 8.4 release planning
Next
From: Stefan Kaltenbrunner
Date:
Subject: Re: Commitfest infrastructure (was Re: 8.4 release planning)