I have a brand new install of MySQL 5.6.20 and now get these messages from my front-end when I am loading up the new database.

[Err] 2013 - Lost connection to MySQL server during query
[Err] Alter table address add Foreign Key (zip) references zip (zip) on delete  restrict on update  restrict;

This is what the log is saying

2014-09-24 22:26:23 4091 [ERROR] InnoDB: Failed to find tablespace for table '"foo"."author"' in the cache. Attempting to load the tablespace with space id 56.

2014-09-24 22:26:23 82eb68c00 InnoDB: Operating system error number 2 in a file operation. InnoDB: The error means the system cannot find the path specified.

2014-09-24 22:26:23 4091 [ERROR] InnoDB: Could not find a valid tablespace file for 'foo/author'. See http://dev.mysql.com/doc/refman/5.6/en/innodb-troubleshooting-datadict.html for how to resolve the issue.

2014-09-24 22:26:23 4091 [Warning] InnoDB: Orphan table encountered during DROP DATABASE. This is possible if 'foo/author.frm' was lost.

2014-09-24 22:26:23 4091 [Warning] InnoDB: Missing foo/author.ibd file for table foo/author.

I've never seen this before. If I load the exact same database on an older version of MySQL on a totally different machine, it loads just fine. I've increased the max_allowed_packet variable to 64M but this didn't help.

The SQL is comprised of CREATE TABLE statements and then after the tables are created, then the Alter table statements are executed.

Has anyone else run into this issue with 5.6.20? If so, what is the fix?

  • Did you try alter table import tablespace ? make sure all tables are imported correctly especially if you use InnoDB – Alin Andrei Sep 25 '14 at 12:46

I have never experienced it, but it could look like the query broke mid transaction

  • Try and see if you can force the transaction to continue.
  • Try and just commit, see if that opens up.
  • And last but not least, try and rollback and see if that could free the transaction.

Thats my 5 cents.


|improve this answer|||||

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.