Not the answer you need?
Register and ask your own question!

ERROR 1146 (42S02): Tablespace doesn't exist after Xtrabackup Restore

SupriyaSupriya Current User Role Contributor
edited October 29 in Percona XtraBackup

I had 1.4 Tb of mysql database which I migrated over network using streaming and compression.

On Source-- Mysql 5.6

On Destination -- MySQL 5.7

I followed below steps.

On Old Server


sudo innobackupex --user=MYSQL-USER --password=MYSQL-PASSOWORD --stream=xbstream --compress --compress-threads=3 --parallel=4 . | ssh -T -o Compression=no [email protected] 'cat - > /data/full/backup.xbstream'

On New Server


xbstream -x < backup.xbstream -C /data/backup/

cd /data

mkdir mysql

sudo chown mysql.mysql mysql -R

sudo chmod 775 mysql -R

mv backup/* mysql/.

xtrabackup --decompress --parallel=12 --remove-original --target-dir=/data/mysql

xtrabackup --prepare --apply-log --use-memory=100G --target-dir=/data/mysql

sudo chown mysql.mysql /data/mysql -R

Started Mysql 5.7 and did mysql.upgrade

I got error for my partitioned table as follows.

mysql> show create table table1;

ERROR 1812 (HY000): Tablespace is missing for table `new`.`table1`.


  • Marcelo AltmannMarcelo Altmann Percona Staff Role

    Hi Supriya,

    Please share the logs of backup/decompres/prepare and mysql so we can check what went wrong.

  • SupriyaSupriya Current User Role Contributor

    Hello Marcelo,

    Sorry, I had skipped --prepare step which resulted into DB crash.

    Anyways, thank you for your reply.

Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.