# # Bug 42074 concurrent optimize table and # alter table = Assertion failed: thd->is_error() # DROP TABLE IF EXISTS t1; # Create InnoDB table CREATE TABLE t1 (id INT) engine=innodb; # Connection 1 # Start optimizing table SET DEBUG_SYNC='ha_admin_try_alter SIGNAL optimize_started WAIT_FOR table_altered'; OPTIMIZE TABLE t1; # Connection 2 # Change table to engine=memory SET DEBUG_SYNC='now WAIT_FOR optimize_started'; ALTER TABLE t1 engine=memory; SET DEBUG_SYNC='now SIGNAL table_altered'; # Connection 1 # Complete optimization Table Op Msg_type Msg_text test.t1 optimize note Table does not support optimize, doing recreate + analyze instead test.t1 optimize error Got error -1 from storage engine test.t1 optimize status Operation failed Warnings: Error 1030 Got error -1 from storage engine DROP TABLE t1; SET DEBUG_SYNC='RESET'; # # Bug#47459 Assertion in Diagnostics_area::set_eof_status on # OPTIMIZE TABLE # DROP TABLE IF EXISTS t1; CREATE TABLE t1(a INT) ENGINE= InnoDB; # Connection con1 SET DEBUG_SYNC= "ha_admin_open_ltable SIGNAL opening WAIT_FOR dropped"; # Sending: OPTIMIZE TABLE t1; # Connection default SET DEBUG_SYNC= "now WAIT_FOR opening"; DROP TABLE t1; SET DEBUG_SYNC= "now SIGNAL dropped"; # Connection con1 # Reaping: OPTIMIZE TABLE t1 Table Op Msg_type Msg_text test.t1 optimize note Table does not support optimize, doing recreate + analyze instead test.t1 optimize error Table 'test.t1' doesn't exist test.t1 optimize status Operation failed Warnings: Error 1146 Table 'test.t1' doesn't exist # Connection default SET DEBUG_SYNC= "RESET"; # # Bug#53757 assert in mysql_truncate_by_delete # DROP TABLE IF EXISTS t1, t2; CREATE TABLE t1(a INT) Engine=InnoDB; CREATE TABLE t2(id INT); INSERT INTO t1 VALUES (1), (2); INSERT INTO t2 VALUES(connection_id()); SET DEBUG_SYNC= "open_and_process_table SIGNAL opening WAIT_FOR killed"; # Sending: (not reaped since connection is killed later) TRUNCATE t1; SET DEBUG_SYNC= "now WAIT_FOR opening"; SELECT ((@id := id) - id) FROM t2; ((@id := id) - id) 0 KILL @id; SET DEBUG_SYNC= "now SIGNAL killed"; DROP TABLE t1, t2;