Re: Clean shutdown and warm standby - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: Clean shutdown and warm standby
Date
Msg-id 49F71F2A.9000107@enterprisedb.com
Whole thread Raw
In response to Re: Clean shutdown and warm standby  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Clean shutdown and warm standby  (Guillaume Smet <guillaume.smet@gmail.com>)
List pgsql-hackers
Tom Lane wrote:
> Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
>> Andreas Pflug wrote:
>>> So to get this down to a solution, it appears to be correct to execute 
>>> the RequestXLogSwitch right before CreateCheckPoint?
> 
>> Hmm, then the checkpoint record isn't archived. That might be 
>> acceptable, though, since all data would be safe in the preceding WAL.
> 
> Not at all, because the database would be very unhappy at restart
> if it can't find the checkpoint record pg_control is pointing to.

At a normal startup, the checkpoint record would be there as usual. And 
an archive recovery starts at the location indicated by the backup label.

AFAICS calling RequestXLogSwitch() before CreateCheckPoint would be 
equivalent to calling "pg_switch_xlog()" just before shutting down.

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


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: idea: global temp tables
Next
From: "vacuum"
Date:
Subject: Re: idea: global temp tables