Pivotal Knowledge Base

Follow

How to activate standby master?

Environment

Product Version
Pivotal Greenplum (GPDB) 4.3.x
OS ALL
Others  

Purpose
If GPDB master is not functional for any reason, to ensure a high business availability it is necessary to bring up the standby master immediately. This article is to describe the procedure to activate standby master.
 

Procedure

1. Before activating standby master, please ensure the synchronization state  is "sync". You can check sync state between primary master and standby master using "gpstate -f". 
The sync should be normal if there is output as follows:

WAL Sender State: streaming
Sync state: sync

2. Immediately  bring the primary master down, if the master process is still up:

$ gpstop -m

3. Log in to the standby master and use following command to activate standby master:

$ gpactivatestandby -d $MASTER_DATA_DIRECTORY

4. Once switched successfully, analyze DBs:

$ psql -d <db_name> -c "ANALYZE"

5. Change the IP configured on clients to the IP of standby master if needed.

 

 

Comments

Powered by Zendesk