mxdeletesystem

Delete YMatrix DB instances and data.

1 Description

  • Function
    • The mxdeletes system tool stops the postgres process on all Segment instances and Master instances, and deletes all data directories, restoring the system to the deployment database before replacing the system.
  • Preparation
    • Move all backup files out of the master data directory and the data node (Segment) data directory.
    • Make sure YMatrix is ​​running.
    • If you are currently in the Segment data directory, change the directory to another location. When running from the Segment data directory, the tool fails with an error.

Notes!
mxdeletesystem will only delete database instances and data, and will not delete mxadmin users of the operating system, nor will the YMatrix software be uninstalled.

2 Parameter Options

| Parameter name | Description | | ------------------------------------------------------------------------------------------------------------------------------- | -c or --db-cluster-id | The ID of the target database cluster, if the parameter is omitted, the default ID is used | | -a or --no-prompt | By default, the user will be prompted to confirm the deletion. Setting this option will not prompt the user to confirm | | -t or --timeout | Command timeout, default is 1 minute | | -q or --quiet | Run in silent mode. Command output is not displayed on the screen, but is still written to the log file | | -h or --help | Show Help Information |

3 Examples

Delete a database cluster and confirm the deletion after printing the cluster information.

Notes!
mxdeletesys need to be executed on users with sudo permissions in the master node (except mxadmin) (except mxadmin, the absolute path `/opt/ymatrix/matrixdb5/bin/mxdeletesysysys.

$ mxdeletesystem

Delete a database cluster and directly execute deletion.

$ mxdeletesystem -a

Notes!
YMatrix 5 deploys a brand new database schema, enables the mxdetetesystem tool to delete clusters, which are incompatible with gpdeletesystem. Previous versions were available using the gpdeletesysystem tool.

See also: mxaddmirrors, mxinitstandby.