Answer the question
In order to leave comments, you need to log in
How to restore a separate database using mariabackup?
How to restore a separate database using mariabackup?
I do backup like this
mariabackup --backup \
--databases=db_name \
--stream=xbstream | gzip > /root/backupstream.gz
gunzip -c backupstream.gz | mbstream -x
mariabackup --prepare --export \
--target-dir=/target/dir/
For a partial backup, there are a few other arguments that you can provide as well:
To tell it which databases to backup, you can provide the --databases optio
The restore process for partial backups is quite different than the process for full backups. A partial backup is not a completely functional data directory. The data dictionary in the InnoDB system tablespace will still contain entries for the databases and tables that were not included in the backup.
Rather than using the --copy-back or the --move-back, each individual InnoDB file-per-table tablespace file will have to be manually imported into the target server. The process that is used to import the file will depend on whether partitioning is involved.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question