I'm using Xtrabackup to perform a MySQL DB restore.

I found some problems when I'm trying to restore individual tables: tables with InnoDB engine can be restored without any problem but I can't find a way to backup and restore MyISAM tables. Is there a way to restore MyISAM individual tables with Xtrabackup or similar products?

  • xtrabackup copies MyISAM tables as well. How do you run xtrabackup? – akuzminsky Aug 8 '17 at 8:40
  • with this command: innobackupex --apply-log --export /path/to/backup – Dandelion Aug 8 '17 at 8:44
  • I meant how do you take backups. Anyways, are there *.MYD, *MYI files in the backup? – akuzminsky Aug 8 '17 at 8:47
  • Yes, both *.MYD and *.MYI file are present in the backup directory. – Dandelion Aug 8 '17 at 9:08
  • 1
    To restore individual MyISAM tables you can copy table.{frm,MYD,MYI} files , execute FLUSH TABLES (yes, mysqld may be running) and the restored version will be available on MySQL instance. – akuzminsky Aug 8 '17 at 9:12

To restore individual MyISAM tables from XtraBackup:

  • Copy table.{frm,MYD,MYI} files to MySQL database directory e.g /var/lib/mysql/sakila
  • Execute FLUSH TABLES (yes, mysqld may be running)
  • Check the restored version is available on MySQL instance with SHOW TABLES and selecting rows from them.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.