Restore single database from full Xtrabackup backup
Percona Xtrabackup does not have any direct way to import single database. I have found a script to restore single database written by Phil Buescher . I have made few changes in the script. There are few perquisite to run the script. You can download the script from here . You need to use mysql-utility mysqlfrm to get the structure of the table from backup. But mysqlfrm works only for innodb tables. Prerequisite: 1. Table should be innodb engine. 2. innodb_file_per_table option should be enabled on the source server before taking the backup. 3. If you have any view inside your backup directory, script will fail. It will print the name of the file where it failed. You need to go inside backup directory and delete all the files related to those views. For restoring DB we need to have all the following backups. I am referring to the directory structure creat...