[MDEV-17145] Unexpected ER_LOCK_WAIT_TIMEOUT upon locking a MERGE table Created: 2018-09-06  Updated: 2023-04-27

Status: Open
Project: MariaDB Server
Component/s: Locking, Tests
Affects Version/s: 10.0, 10.1, 10.2, 10.3
Fix Version/s: 10.4

Type: Bug Priority: Major
Reporter: Elena Stepanova Assignee: Sergei Golubchik
Resolution: Unresolved Votes: 0
Labels: regression


 Description   

connect (con1,localhost,root,,);
SET lock_wait_timeout=1;
 
connection default;
CREATE TABLE t (id INT) ENGINE=MyISAM;
CREATE TABLE t1 (id INT) ENGINE=MRG_MYISAM UNION(t);
LOCK TABLE t1 READ;
 
connection con1;
--echo ### HERE: 
LOCK TABLE t1 READ;
 
# Cleanup
disconnect con1;
connection default;
UNLOCK TABLES;
DROP TABLE t1, t;

10.0 09bc99fac

worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
SET lock_wait_timeout=1;
CREATE TABLE t (id INT) ENGINE=MyISAM;
CREATE TABLE t1 (id INT) ENGINE=MRG_MYISAM UNION(t);
LOCK TABLE t1 READ;
### HERE: 
LOCK TABLE t1 READ;
CURRENT_TEST: bug.t4
mysqltest: At line 11: query 'LOCK TABLE t1 READ' failed: 1205: Lock wait timeout exceeded; try restarting transaction
 
 - saving '/data/bld/10.0/mysql-test/var/log/bug.t4/' to '/data/bld/10.0/mysql-test/var/log/bug.t4/'
--------------------------------------------------------------------------
The servers were restarted 0 times
Spent 0.000 of 9 seconds executing testcases
 
Failure: Failed 1/1 tests, 0.00% were successful.

Earlier the test passed. Starting from the revision below, the 2nd LOCK TABLE (under "### HERE") fails with ER_LOCK_WAIT_TIMEOUT.

commit 9180e8666b8e31239d2e2075b703fb8bc8effc13
Author: Sergei Golubchik
Date:   Thu Jul 19 01:03:14 2018 +0200
 
    MDEV-16465 Invalid (old?) table or database name or hang in ha_innobase::delete_table and log semaphore wait upon concurrent DDL with foreign keys


Generated at Thu Feb 08 08:34:15 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.