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

void lock_rec_dequeue_from_page(ib_lock_t*, bool): Assertion `old_n_locks' failed

    XMLWordPrintable

Details

    • Can result in hang or crash

    Description

      Assertion found while testing MDEV-38069

      origin/MDEV-38069 ac77558ba4024cd78a0e12a8364afb105767cdcc

      # 2025-11-12T03:52:05 [472681] | mariadbd: /data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc:2363: void lock_rec_dequeue_from_page(ib_lock_t*, bool): Assertion `old_n_locks' failed.
      

      StackTrace

      # 2025-11-12T03:53:33 [472681] #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
      # 2025-11-12T03:53:33 [472681] #1  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
      # 2025-11-12T03:53:33 [472681] #2  __GI___pthread_kill (threadid=<optimized out>, signo=6) at ./nptl/pthread_kill.c:89
      # 2025-11-12T03:53:33 [472681] #3  0x00005555565b1b6f in my_write_core (sig=6) at /data/Server/MDEV-38069/mysys/stacktrace.c:424
      # 2025-11-12T03:53:33 [472681] #4  0x0000555556047996 in handle_fatal_signal (sig=6) at /data/Server/MDEV-38069/sql/signal_handler.cc:298
      # 2025-11-12T03:53:33 [472681] #5  <signal handler called>
      # 2025-11-12T03:53:33 [472681] #6  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
      # 2025-11-12T03:53:33 [472681] #7  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
      # 2025-11-12T03:53:33 [472681] #8  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
      # 2025-11-12T03:53:33 [472681] #9  0x00007ffff704526e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
      # 2025-11-12T03:53:33 [472681] #10 0x00007ffff70288ff in __GI_abort () at ./stdlib/abort.c:79
      # 2025-11-12T03:53:33 [472681] #11 0x00007ffff702881b in __assert_fail_base (fmt=0x7ffff71d01e8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55555683488f "old_n_locks", file=file@entry=0x55555674bfc8 "/data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc", line=line@entry=2363, function=function@entry=0x555556750aa0 "void lock_rec_dequeue_from_page(ib_lock_t*, bool)") at ./assert/assert.c:94
      # 2025-11-12T03:53:33 [472681] #12 0x00007ffff703b507 in __assert_fail (assertion=0x55555683488f "old_n_locks", file=0x55555674bfc8 "/data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc", line=2363, function=0x555556750aa0 "void lock_rec_dequeue_from_page(ib_lock_t*, bool)") at ./assert/assert.c:103
      # 2025-11-12T03:53:33 [472681] #13 0x00005555562febd5 in lock_rec_dequeue_from_page (in_lock=in_lock@entry=0x7ffff521ab00, owns_wait_mutex=owns_wait_mutex@entry=false) at /data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc:2363
      # 2025-11-12T03:53:33 [472681] #14 0x000055555630100d in lock_release_try (trx=trx@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc:4354
      # 2025-11-12T03:53:33 [472681] #15 0x0000555556303632 in lock_release (trx=trx@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/lock/lock0lock.cc:4401
      # 2025-11-12T03:53:33 [472681] #16 0x0000555556440c37 in trx_t::release_locks (this=this@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0trx.cc:485
      # 2025-11-12T03:53:33 [472681] #17 0x000055555643c72f in trx_t::commit_in_memory (mtr=0x7fffd1dfd4e0, this=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0trx.cc:1442
      # 2025-11-12T03:53:33 [472681] #18 trx_t::commit_low (this=this@entry=0x7ffff521aa00, mtr=0x7fffd1dfd4e0) at /data/Server/MDEV-38069/storage/innobase/trx/trx0trx.cc:1589
      # 2025-11-12T03:53:33 [472681] #19 0x000055555643d2b9 in trx_t::commit_persist (this=this@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0trx.cc:1603
      # 2025-11-12T03:53:33 [472681] #20 0x000055555643d316 in trx_t::commit (this=this@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0trx.cc:1612
      # 2025-11-12T03:53:33 [472681] #21 0x00005555564322cc in trx_t::rollback_finish (this=this@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0roll.cc:63
      # 2025-11-12T03:53:33 [472681] #22 0x0000555556432a94 in trx_t::rollback_low (this=this@entry=0x7ffff521aa00, savept=savept@entry=0x0) at /data/Server/MDEV-38069/storage/innobase/trx/trx0roll.cc:124
      # 2025-11-12T03:53:33 [472681] #23 0x00005555564330c0 in trx_rollback_for_mysql (trx=trx@entry=0x7ffff521aa00) at /data/Server/MDEV-38069/storage/innobase/trx/trx0roll.cc:213
      # 2025-11-12T03:53:33 [472681] #24 0x0000555556284d1d in innobase_rollback (thd=<optimized out>, rollback_trx=true) at /data/Server/MDEV-38069/storage/innobase/handler/ha_innodb.cc:4640
      # 2025-11-12T03:53:33 [472681] #25 0x000055555604c9b9 in ha_rollback_trans (thd=thd@entry=0x7fff20000d58, all=all@entry=true) at /data/Server/MDEV-38069/sql/handler.cc:2318
      # 2025-11-12T03:53:33 [472681] #26 0x0000555555f1a94b in trans_rollback (thd=thd@entry=0x7fff20000d58) at /data/Server/MDEV-38069/sql/transaction.cc:391
      # 2025-11-12T03:53:33 [472681] #27 0x0000555555de2019 in mysql_execute_command (thd=thd@entry=0x7fff20000d58, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /data/Server/MDEV-38069/sql/sql_parse.cc:5867
      # 2025-11-12T03:53:33 [472681] #28 0x0000555555de38da in mysql_parse (thd=thd@entry=0x7fff20000d58, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x7fffd1dfe3f0) at /data/Server/MDEV-38069/sql/sql_parse.cc:8219
      # 2025-11-12T03:53:33 [472681] #29 0x0000555555de4f46 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x7fff20000d58, packet=packet@entry=0x7fff2000b069 " ROLLBACK  /* E_R Thread14 QNO 336 CON_ID 82 */ ", packet_length=packet_length@entry=48, blocking=blocking@entry=true) at /data/Server/MDEV-38069/sql/sql_parse.cc:1921
      # 2025-11-12T03:53:33 [472681] #30 0x0000555555de63e4 in do_command (thd=thd@entry=0x7fff20000d58, blocking=blocking@entry=true) at /data/Server/MDEV-38069/sql/sql_parse.cc:1434
      # 2025-11-12T03:53:33 [472681] #31 0x0000555555f0978b in do_handle_one_connection (connect=<optimized out>, connect@entry=0x555557dea108, put_in_cache=put_in_cache@entry=true) at /data/Server/MDEV-38069/sql/sql_connect.cc:1475
      # 2025-11-12T03:53:33 [472681] #32 0x0000555555f0999c in handle_one_connection (arg=0x555557dea108) at /data/Server/MDEV-38069/sql/sql_connect.cc:1387
      # 2025-11-12T03:53:33 [472681] #33 0x00007ffff709ca94 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:447
      # 2025-11-12T03:53:33 [472681] #34 0x00007ffff7129c3c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:78
      

      Core dump is present on SDP:-
      /data/results/1762937427/TBR-850

      Attachments

        Issue Links

          Activity

            People

              saahil Saahil Alam
              saahil Saahil Alam
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Git Integration

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