1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Fixed assertion Assertion `!table->pos_in_locked_tables' failed

MDEV-17717
Assertion `!table->pos_in_locked_tables' failed in tc_release_table on
flushing RocksDB table under SERIALIZABLE
MDEV-17998
Deadlock and eventual Assertion `!table->pos_in_locked_tables' failed
in tc_release_table on KILL_TIMEOUT
MDEV-19591
Assertion `!table->pos_in_locked_tables' failed in tc_release_table upon
altering table into S3 under lock.

The problem was that thd->open_tables->pos_in_locked_tables was not reset
when alter table failed to reopen a locked table.
This commit is contained in:
Monty
2019-08-08 20:10:00 +03:00
parent dbac2039e8
commit 6765cc6077
5 changed files with 54 additions and 0 deletions

View File

@ -399,3 +399,20 @@ DROP USER u1@localhost;
SET DEBUG_SYNC = 'RESET';
DROP FUNCTION MY_KILL;
set global sql_mode=default;
#
# MDEV-17998
# Deadlock and eventual Assertion `!table->pos_in_locked_tables' failed
# in tc_release_table on KILL_TIMEOUT
#
SET max_statement_time= 2;
CREATE TABLE t1 (a INT);
CREATE VIEW v1 AS SELECT * FROM t1;
CREATE TABLE t2 (b INT, c INT);
LOCK TABLES v1 READ, t2 WRITE, t1 WRITE;
ALTER TABLE t1 CHANGE f1 f2 DOUBLE;
Got one of the listed errors
ALTER TABLE t2 DROP c;
ERROR 70100: Query execution was interrupted (max_statement_time exceeded)
UNLOCK TABLES;
DROP VIEW v1;
DROP TABLE t1, t2;