Bug #48842 MySQL Backup: RESTORE of compressed MyISAM table throws unwanted warnings
Submitted: 17 Nov 2009 16:14 Modified: 19 Apr 2010 7:18
Reporter: Ingo Strüwing Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Backup Severity:S3 (Non-critical)
Version:6.0-backup OS:Any
Assigned to: Assigned Account CPU Architecture:Any

[17 Nov 2009 16:14] Ingo Strüwing
Description:
RESTORE of a compressed MyISAM table issues two warnings:
"Table is read only" and "Deadlock found when trying to get lock".
This results from an internal call of FLUSH TABLES.
RESTORE can't get back its write lock on the now compressed table.
But it doesn't need the locks any more at this moment.
So it's not a failure of the operation and nothing to worry about.

Hence the warnings should not show up.

How to repeat:
Run the test case backup.backup_myisam. Look at the result file. You will find the comment "RESTORE of a compressed MyISAM table issues two warnings:..." and the warnings below it.

Suggested fix:
Filter the named warnings.
[17 Nov 2009 18:02] Ingo Strüwing
Note the "Version" field. This happens only in the mysql-6.0-backup tree for now.
[8 Mar 2010 14:31] Ritheesh Vedire
In mysql-6.0-backup, the warnings are due to 
1) ER_OPEN_AS_READ_ONLY  in get_lock_data() (lock.cc)
2) ER_LOCK_DEADLOCK      in Locked_tables_list::reopen_tables() (sql_base.cc)