mxrecover

Recovers a YMatrix database system.

1 Description

The mxrecover tool uses a failback mechanism to recover failed nodes in the cluster.

2 Options

Option Description
-c or --db-cluster-id Specifies the target database cluster ID. If omitted, the default value mdw is used as the cluster ID.
-F or --force-full-resync Forces a full resynchronization of Primary/Master data to repair a damaged Mirror/Standby.
-r or --rebalance After recovering failed Segments/Masters, restores all Segments/Masters within each shard to their original Primary/Master or Mirror/Standby roles as defined at initial database setup.
-q Runs in quiet mode. Suppresses command output on the terminal, but logs are still written to the log file.
-h or --help Displays help information.
-Q or --query Periodically prints recovery progress.

Note!
Both mxrecover and mxrecover -F only initiate recovery requests and do not wait for completion. The recovery process runs in the background, allowing you to continue other client operations without blocking. However, no progress or final status is displayed automatically. Use mxrecover -Q or mxrecover --query to manually check the recovery status.

Note!
When mxrecover is run with no options or only the -c option, an incremental recovery is initiated.

3 Examples

Recover a failed Segment/Master:

mxrecover

Perform a full recovery of a failed Segment/Master:

mxrecover -F

#or

mxrecover --force-full-resync

Restore Segment/Master roles:

mxrecover -r

#or

mxrecover --rebalance

Note!
YMatrix 5 introduces a new database architecture and uses the mxrecover tool for cluster recovery. It is incompatible with gprecoverseg. In earlier versions, use the gprecoverseg tool.

See Also: mxstart, mxstop, mxstate