YMatrix
Cluster Deployment
Data Model
Data Writing
Data Query
SQL Reference
Maintenance and Monitoring
Tool Guide
Troubleshooting
gpinitstandby adds Standby for backup to the Master nodes of the MatrixDB cluster. This tool is only available on Master hosts. Before running, make sure that the MatrixDB database software is installed on the host to Standby and that the SSH keys have been exchanged between the hosts. It is recommended to set the port number to the same on the Master host and the Standby host.
Standby is consistent with Master through transaction logs, replication processes (walsender and walreceiver). When the Master node goes down, the Standby node is directly activated as the new Master node. The activation command is gpactivatestandby
Parameter name | Description |
---|---|
-a | Do not prompt the user to confirm. |
-D | Set the log level to debug. |
-l logfile_directory | Directory written to the log, default is ~/gpAdminLogs. |
-n | Specify this option to start a Standby that has been configured but has been stopped for some reason. |
-P port | Specify the port of Standby, the default value is the port used by Master. If Standby and Master are on the same host, the ports must be different. |
-q | Operate in silent mode. The command output is not displayed on the screen, but is still written to the log file. |
-r | Remove the currently configured Standby from the MatrixDB cluster. |
-s standby_hostname | Specify the host name of Standby. |
-S standby_data_directory | Data directory used by new Standby. The default is the same as the Master's data directory. If Standby and Master are on the same host, you must use this option to specify a different path. |
-v | Shows the version, status, date of last updated, and checksum of the tool. |
-? | Show help information. |
Add a new Standby on host09 and specify the port number:
gpinitstandby -s host09 -P 2222
Start Standby configured previously and synchronize it with Master Save:
gpinitstandby -n
Delete an existing Standby:
gpinitstandby -r