[Pgpool-general] Online recovery by PITR questions

Yoshiyuki Asaba y-asaba at sraoss.co.jp
Wed May 14 02:58:52 UTC 2008


Hi,

From: Nico -telmich- Schottelius <nico-pgpool at schottelius.org>
Subject: Re: [Pgpool-general] Online recovery by PITR questions
Date: Thu, 8 May 2008 18:39:21 +0200

> Just to summarise it:

Thanks.


> The scripts
>    pgpool_remote_start, 
>    recovery_1st_stage_command = 'copy-base-backup' and
>    recovery_2nd_stage_command = 'pgpool_recovery_pitr'
> 
>    - must reside in the datadir of all backends
>    - get the parameters
>       DATA=$1
>       RECOVERY_TARGET=$2
>       RECOVERY_DATA=$3
>    - are called on some master node that is known to pgpool
> 
> The whole recovery process done by
>    - manually issue pcp_recovery_node
>    - pgpool executes CHECKPOINT on a master node
>    - pgpool executes SELECT pgpool_recovery('recovery-script,'target','PGDATA')"
>      on a master node
>    - This calls copy-base-backup
>    - UNCLEAR: This also calls pgpool_recovery_pitr?

Yes.


>    - After that pgpool_remote_start is called by pgpool on master
>    - Then postgres does PITR
>    - Then the recovered postgres-server accepts connections again
>       UNCLEAR: -> How does pgpool detect when the postgresql-server is available
>       again?

pgpool connect to the target node. If it cannot connect, it retries to
connect for recovery_timeout seconds.


>    - Then it is attached to the cluster again
>    - normal operation continues, all databases are accessable again

Regards,
--
Yoshiyuki Asaba
y-asaba at sraoss.co.jp


More information about the Pgpool-general mailing list