[pgpool-general: 2303] Re: online recovery

Tatsuo Ishii ishii at postgresql.org
Tue Nov 19 23:34:39 JST 2013

> I was reading in the manual about online recovery.  Is this only available
> when pgpool is running in replication mode?

No. Online recovery can be used with streaming replication mode.

> I have master/slave mode set
> but it doesn't seem to be working correctly.
> master_slave_mode = on
> master_slave_sub_mode = 'stream'
> load_balance_mode = on
> failover_command = '/var/lib/pgsql/9.2/failover.sh %d %P %H %R'
> recovery_user = 'postgres'
> recovery_1st_stage_command = '/var/lib/pgsql/9.2/sendbackup.sh %H
> /var/lib/pgsql/9.2/data /var/lib/pgsql/9.2/data/pg_archive'
> failover.sh touches a trigger files on the other db server and sendbackup
> uses rsync to copy over all of the files to the other db, then it restarts
> postgres.

Sounds like your failover.sh does too much. It should just touch
trigger file when primary node fails. Otherwise it should do nothing.

> Under what case would pgpool run the recovery_1st_stage_command?
>  Does this not work with master_slave_mode on?

recovery_1st_stage_command is used when you execute pcp_recovery_node

I recommend you to check:

It was written for pgpool-II 3.1 and PostgreSQL 9.1 (+streaming
replication), it should be used for pgpool-II 3.3.
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese: http://www.sraoss.co.jp

More information about the pgpool-general mailing list