YMatrix
Quick Start
Cluster Deployment
Data Model
Data Writing
Data Query
SQL Reference
Maintenance and Monitoring
Tool Guide
Troubleshooting
mxbackup is used to make parallel backups of clusters. The backup data needs to be restored using mxrestore.
Parameter name | Description |
---|---|
--backup-dir directory | Absolute path to write to the backup file. |
--compression-level level | Compression level, range 1-9, default 1. |
--data-only | Only backup data, not schema. |
--dbname db | The database that needs to be backed up. |
--debug | Output log information at the debug level. |
--exclude-schema schema | Schema excluded during backup. 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 backup. This parameter can be used to specify multiple tables. |
--exclude-table-file file | A list file containing tables to be excluded. |
--from-timestamp timestamp | The start timestamp during incremental backup needs to be used with the --incremental parameter. |
--help | Show help information. |
--history | Shows the historical timestamp of the current backup directory. |
--include-schema schema | Specify the schema that needs to be backed up. You can specify multiple schemas through multiple use. |
--include-schema-file file | Specify the list of schema files that need to be backed up. |
--include-table table | Specify the table that needs to be backed up. You can specify multiple tables through multiple use. |
--include-table-file file | Specify a list file containing the tables to be backed up. |
--incremental | Incremental backup, suitable for AO tables. Need to be used with the --from-timestamp parameter. |
--jobs num | The number of concurrent connections during backup, default is 1. |
--leaf-partition-data | Create separate data files for each partition when backing up partition tables. |
--metadata-only | Only backup metadata, not back up data in tables. |
--no-compression | No compression of table data. |
--plugin-config file | Specify the location of the plug-in configuration file. |
--quiet | Do not display all non-alarm or non-error log information. |
--single-data-file | Back up data to a separate file instead of a table one file. |
--verbose | Print detailed log information. |
--version | Print the tool version number and exit. |
--with-stats | Backup statistics. |
--without-globals | Do not back up global metadata. |
Backup demo
database:
mxbackup --dbname demo
Backup data other than demo
databasetwitter
schema:
mxbackup --dbname demo --exclude-schema twitter
Backup only the data of the demo
databasetwitter
schema:
mxbackup --dbname demo --include-schema twitter
Back up the demo
database and store the backup data to the /home/mxadmin/backup
directory:
mxbackup --dbname demo --backup-dir /home/mxadmin/backup