Delete behavior is issued at 4 o'clock in the morning, Just landed during the backup, because 5.5 had MDL (Meta data Lock), so when –single-transaction, the tables that were manipulated within the transaction would hold the MDL and therefore not be destroyed by the DDL. So, view get_ Status.err will have the following log:
< Span style= "Word-wrap:break-word; Orphans:2; Text-align:-webkit-auto; Widows:2; " >11966363,hardcore,localhost,oss_log,query,11084,waiting for table metadata Lock,drop table 2014_10_17_oss_ ABANDONQUEST
The MDL mechanism of 5.5 is that if a transaction is not released, the table involved in the transaction will hold the DML lock on the table, the transaction will not be released, and the lock will not be released. The MDL mechanism of 5.0 and 5.1 is irrelevant to the transaction, as long as the statement ends, the MDL lock held by the statement is freed. This is the difference between the two, and indeed the table engine doesn't matter.
Here is a test:
|
|
Session.1 |
|
|
|
Session.2 |
|
|
|
|
|
|
|
|
|
|
|
Step.1 |
|
Begin |
|
|
|
|
|
|
Step.2 |
|
SELECT * from Tb_myisam; |
|
|
|
|
Step.3 |
|
|
|
|
|
drop table Tb_myisam; |
|
|
|
|
|
|
Be blocked ... |
is the MySQL MDL related to the storage engine?