Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-34542

Assertion `lock_trx_has_sys_table_locks(trx) == __null' failed in void row_mysql_unfreeze_data_dictionary(trx_t*)

    XMLWordPrintable

Details

    Description

      --source include/have_innodb.inc
      --source include/have_partition.inc
       
      CREATE TABLE t3 (c1 CHAR(1) ,c2 INT) ENGINE=INNODB PARTITION BY LINEAR HASH ((c2)) PARTITIONS 512;
      CREATE TABLE t (a INT) ENGINE=INNODB;
      XA START 'a';
      INSERT INTO mysql.innodb_index_stats SELECT * FROM mysql.innodb_index_stats WHERE table_name='';
      SET GLOBAL table_open_cache=10;
      INSERT t (a) VALUES (1);
      SELECT * FROM t3;
      XA END 'a';
      XA PREPARE 'a';
      SELECT SLEEP (3);
      CACHE INDEX tb1,tb2 IN DEFAULT;
      

      Leads to:

      10.5.26 33964984ad69379abb01d1a2fb0f5a285a58f906 (Debug)

      mariadbd: /test/10.5/storage/innobase/row/row0mysql.cc:2040: void row_mysql_unfreeze_data_dictionary(trx_t*): Assertion `lock_trx_has_sys_table_locks(trx) == __null' failed.
      

      10.5.26 33964984ad69379abb01d1a2fb0f5a285a58f906 (Debug)

      Core was generated by `/test/MD270624-mariadb-10.5.26-linux-x86_64-dbg/bin/mariadbd --no-defaults --ma'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      [Current thread is 1 (Thread 0x1478740e1700 (LWP 2074585))]
      (gdb) bt
      #0  __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:56
      #1  0x000055c4ff668c99 in my_write_core (sig=sig@entry=6) at /test/10.5/mysys/stacktrace.c:424
      #2  0x000055c4feeb2714 in handle_fatal_signal (sig=6) at /test/10.5/sql/signal_handler.cc:357
      #3  <signal handler called>
      #4  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      #5  0x000015034b6e5859 in __GI_abort () at abort.c:79
      #6  0x000015034b6e5729 in __assert_fail_base (fmt=0x15034b87b588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55c4ffa9e8a8 "lock_trx_has_sys_table_locks(trx) == __null", file=0x55c4ffa9e2e0 "/test/10.5/storage/innobase/row/row0mysql.cc", line=2040, function=<optimized out>) at assert.c:92
      #7  0x000015034b6f6fd6 in __GI___assert_fail (assertion=assertion@entry=0x55c4ffa9e8a8 "lock_trx_has_sys_table_locks(trx) == __null", file=file@entry=0x55c4ffa9e2e0 "/test/10.5/storage/innobase/row/row0mysql.cc", line=line@entry=2040, function=function@entry=0x55c4ffa9e8d8 "void row_mysql_unfreeze_data_dictionary(trx_t*)") at assert.c:101
      #8  0x000055c4ff3741a5 in row_mysql_unfreeze_data_dictionary (trx=trx@entry=0x15034aeee188) at /test/10.5/storage/innobase/row/row0mysql.cc:2040
      #9  0x000055c4ff3c4991 in row_undo (thr=0x1502e81ac6a0, node=0x1502e84b4910) at /test/10.5/storage/innobase/row/row0undo.cc:433
      #10 row_undo_step (thr=thr@entry=0x1502e81ac6a0) at /test/10.5/storage/innobase/row/row0undo.cc:476
      #11 0x000055c4ff30aaed in que_thr_step (thr=0x1502e81ac6a0) at /test/10.5/storage/innobase/que/que0que.cc:863
      #12 que_run_threads_low (thr=0x1502e81ac6a0) at /test/10.5/storage/innobase/que/que0que.cc:927
      #13 que_run_threads (thr=<optimized out>) at /test/10.5/storage/innobase/que/que0que.cc:967
      #14 0x000055c4ff42866c in trx_t::rollback_low (savept=0x0, this=0x15034aeee188) at /test/10.5/storage/innobase/trx/trx0roll.cc:124
      #15 trx_rollback_for_mysql_low (trx=trx@entry=0x15034aeee188) at /test/10.5/storage/innobase/trx/trx0roll.cc:192
      #16 0x000055c4ff42934d in trx_rollback_for_mysql (trx=trx@entry=0x15034aeee188) at /test/10.5/storage/innobase/trx/trx0roll.cc:263
      #17 0x000055c4ff1d7a0d in innobase_rollback (hton=<optimized out>, thd=0x1502e8000d48, rollback_trx=<optimized out>) at /test/10.5/storage/innobase/handler/ha_innodb.cc:4479
      #18 0x000055c4feeb7331 in ha_rollback_trans (thd=thd@entry=0x1502e8000d48, all=all@entry=true) at /test/10.5/sql/handler.cc:2142
      #19 0x000055c4fed59db8 in trans_rollback_implicit (thd=thd@entry=0x1502e8000d48) at /test/10.5/sql/transaction.cc:421
      #20 0x000055c4fed58345 in mysql_admin_table (thd=thd@entry=0x1502e8000d48, tables=tables@entry=0x1502e80140a8, check_opt=check_opt@entry=0x15034a0fbd40, operator_name=operator_name@entry=0x55c4ff83d739 "assign_to_keycache", lock_type=lock_type@entry=TL_READ_NO_INSERT, org_open_for_modify=org_open_for_modify@entry=false, repair_table_use_frm=false, extra_open_options=0, prepare_func=0x0, operator_func=&virtual table offset 736, view_operator_func=0x0, is_cmd_replicated=false) at /test/10.5/sql/sql_admin.cc:1301
      #21 0x000055c4fed588d2 in mysql_assign_to_keycache (thd=thd@entry=0x1502e8000d48, tables=tables@entry=0x1502e80140a8, key_cache_name=key_cache_name@entry=0x1502e8005a90) at /test/10.5/sql/sql_admin.cc:1411
      #22 0x000055c4fec06c87 in mysql_execute_command (thd=thd@entry=0x1502e8000d48) at /test/10.5/sql/sql_parse.cc:4161
      #23 0x000055c4febf371d in mysql_parse (thd=thd@entry=0x1502e8000d48, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x15034a0fc310, is_com_multi=is_com_multi@entry=false, is_next_command=is_next_command@entry=false) at /test/10.5/sql/sql_parse.cc:8221
      #24 0x000055c4fec01b95 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x1502e8000d48, packet=packet@entry=0x1502e800aac9 "", packet_length=packet_length@entry=30, is_com_multi=is_com_multi@entry=false, is_next_command=is_next_command@entry=false) at /test/10.5/sql/sql_class.h:1329
      #25 0x000055c4fec04523 in do_command (thd=0x1502e8000d48) at /test/10.5/sql/sql_parse.cc:1376
      #26 0x000055c4fed45d73 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55c501a4e478, put_in_cache=put_in_cache@entry=true) at /test/10.5/sql/sql_connect.cc:1417
      #27 0x000055c4fed46244 in handle_one_connection (arg=0x55c501a4e478) at /test/10.5/sql/sql_connect.cc:1319
      #28 0x000015034bbf6609 in start_thread (arg=<optimized out>) at pthread_create.c:477
      #29 0x000015034b7e2133 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      

      Bug confirmed present in:
      MariaDB: 10.5.26 (dbg)

      Bug (or feature/syntax) confirmed not present in:
      MariaDB: 10.5.26 (opt), 10.6.19 (dbg), 10.6.19 (opt), 10.11.9 (dbg), 10.11.9 (opt), 11.1.6 (dbg), 11.1.6 (opt), 11.2.4 (dbg), 11.2.4 (opt), 11.4.2 (dbg), 11.4.2 (opt), 11.5.2 (dbg), 11.5.2 (opt)

      Attachments

        Activity

          People

            thiru Thirunarayanan Balathandayuthapani
            ramesh Ramesh Sivaraman
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.