mysqldump: Got error: 1146: Table '' doesn't exist when using LOCK TABLES

Created:

2017-01-11 14:20:23 UTC

Modified:

2017-08-12 23:21:11 UTC

0

Was this article helpful?


Have more questions?

Submit a request

mysqldump: Got error: 1146: Table '' doesn't exist when using LOCK TABLES

Symptoms

Trying to Export Dump at Plesk > Domains > example.com > Databases > TABLENAME the following error appear:

Unable to export a dump of TABLENAME: 
Unable to backup database 'TABLENAME' 
mysqldump: Got error: 1146: Table 'TABLENAME.col1' doesn't exist when using LOCK TABLES (Error code 21) 


Backup of the subscription is completed with a warning:

Warning: domain "example.com" 
Cannot dump database content 'TABLENAME' of type 'mysql'
[ Cannot backup content of database 'database_name'. The mysqldump utility has returned '7'. STDERR: mysqldump: unknown variable 'defaults-extra-file=C:\Program Files (x86)\Parallels\Plesk\PrivateTemp\tmp19208.tmp' ]

Cause

There are extra .frm files of InnoDB tables in a database directory.

Resolution

  1. Log into the affected database using the database's user credentials:
    "%plesk_dir%\MySQL\bin\mysql.exe" -uuser -ppassword TABLENAME
  2. Run show tables; and check if a table is listed. If not, move .frm file out from the database directory.
    Database directory is defined as datadir in "%plesk_dir%"Databases/MySQL/data/my.ini file.
Have more questions? Submit a request
Please sign in to leave a comment.