mxrestore is used to restore data backed up using the mxbackup tool.
Parameter name | Description |
---|---|
--backup-dir directory | Absolute path to backup data that needs to be restored. |
--create-db | Create the database before recovering the data. |
--data-only | Only restore data, not meta information. |
--debug | Output log information at the debug level. |
--exclude-schema schema | Schema excluded when recovering. This parameter can be specified by using multiple times. |
--exclude-schema-file file | A list of schemas that need to be excluded. |
--exclude-table table | Table excluded during recovery. This parameter can be used multiple times to specify multiple tables. |
--exclude-table-file file | A list file containing tables to be excluded. |
--help | Show help information. |
--include-schema schema | Specify the schema that needs to be restored. You can specify multiple schemas through multiple use. |
--include-schema-file file | Specify the schema list file that needs to be restored. |
--include-table table | Specify the table to be restored. Multiple tables can be specified by using them multiple times. |
--include-table-file file | Specify a list file containing the tables to be restored. |
--incremental | Incremental recovery, suitable for AO tables. |
--jobs num | The number of concurrent connections during recovery, default is 1. |
--metadata-only | Only restore metadata, not data in tables. |
--on-error-continue | Recover logs and continues when an error is encountered. |
--plugin-config file | Specify the location of the plug-in configuration file. |
--quiet | Do not display all non-alarm or non-error log information. |
--redirect-db db | Restore data to the specified database, not the database used when backing up. |
--redirect-schema schema | Restore data to the specified schema, not the schema used during backup. |
--run-analyze | Run ANALYZE on the recovered table. |
--timestamp timestamp | The timestamp that needs to be used during recovery is in the format YYYYMMDDHHMMSS. |
--truncate-table | Delete the recovered table data. |
--verbose | Print detailed log information. |
--version | Print the tool version number and exit. |
--with-globals | Restore global metadata. |
--with-stats | Recover statistics. |
Restore the backup of the 20210820143820
timestamp in the /home/mxadmin/backup
directory:
mxrestore --backup-dir /home/mxadmin/backup --timestamp 20210820143820