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

Assertion `size == rec_offs_size(*offsets)' failed

    XMLWordPrintable

Details

    • Can result in hang or crash

    Description

      --source include/have_innodb.inc
      --source include/have_debug_sync.inc
      CREATE TABLE t1 (a TEXT, FULLTEXT(a)) ENGINE=InnoDB;
      INSERT INTO t1 VALUES ('a');
      --source include/restart_mysqld.inc
      SET DEBUG_SYNC='fts_initialize_doc_id HIT_LIMIT 1';
      --error ER_DEBUG_SYNC_HIT_LIMIT
      UPDATE t1 SET a=NULL;
      SET DEBUG_SYNC='RESET';
      DROP TABLE t1;
      

      Leads to:

      CS 13.2.0 cf542109f3389838b4b688b78941797f6a95d51f (Debug, Clang 22.1.8-20260621) Build 12/10/2026

      mariadbd: /test/13.1_dbg/storage/innobase/include/page0cur.inl:175: rec_t *page_cur_tuple_insert(page_cur_t *, const dtuple_t *, rec_offs **, mem_heap_t **, ulint, mtr_t *): Assertion `size == rec_offs_size(*offsets)' failed.
      

      CS 13.2.0 cf542109f3389838b4b688b78941797f6a95d51f (Debug, Clang 22.1.8-20260621) Build 12/10/2026

      Core was generated by `/test/MD121026-mariadb-13.2.0-linux-x86_64-dbg/bin/mariadbd --defaults-group-su'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:44
       
      [Current thread is 1 (LWP 1044067)]
      (gdb) bt
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:44
      #1  __pthread_kill_internal (signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:78
      #2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6)at ./nptl/pthread_kill.c:89
      #3  0x00007828c4e4527e in __GI_raise (sig=sig@entry=6)at ../sysdeps/posix/raise.c:26
      #4  0x00007828c4e288ff in __GI_abort () at ./stdlib/abort.c:79
      #5  0x00007828c4e2881b in __assert_fail_base (fmt=0x7828c4fd1208 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x5d433845de28 "size == rec_offs_size(*offsets)", file=file@entry=0x5d433840a1ec "/test/13.1_dbg/storage/innobase/include/page0cur.inl", line=line@entry=175, function=function@entry=0x5d433845de48 "rec_t *page_cur_tuple_insert(page_cur_t *, const dtuple_t *, rec_offs **, mem_heap_t **, ulint, mtr_t *)")at ./assert/assert.c:96
      #6  0x00007828c4e3b517 in __assert_fail (assertion=0x5d433845de28 "size == rec_offs_size(*offsets)", file=0x5d433840a1ec "/test/13.1_dbg/storage/innobase/include/page0cur.inl", line=175, function=0x5d433845de48 "rec_t *page_cur_tuple_insert(page_cur_t *, const dtuple_t *, rec_offs **, mem_heap_t **, ulint, mtr_t *)")at ./assert/assert.c:105
      #7  0x00005d4337d82060 in page_cur_tuple_insert (cursor=0x7828a7558288, tuple=0x7027bc077658, offsets=0x7828a7558008, heap=0x7828a7558268, n_ext=0, mtr=0x7828a7558358) at include/page0cur.inl:175
      #8  0x00005d4337d806b7 in btr_cur_optimistic_insert (flags=0, cursor=0x7828a7558288, offsets=0x7828a7558008, heap=0x7828a7558268, entry=0x7027bc077658, rec=0x7828a7557f90, big_rec=0x7828a7558278, n_ext=0, thr=0x7027bc029240, mtr=0x7828a7558358)at /test/13.1_dbg/storage/innobase/btr/btr0cur.cc:2521
      #9  0x00005d4337c4c61c in row_ins_clust_index_entry_low (flags=0, mode=BTR_MODIFY_LEAF, index=0x702848012328, n_uniq=0, entry=0x7027bc077658, n_ext=0, thr=0x7027bc029240)at /test/13.1_dbg/storage/innobase/row/row0ins.cc:2941
      #10 0x00005d4337c50697 in row_ins_clust_index_entry (index=0x702848012328, entry=0x7027bc077658, thr=0x7027bc029240, n_ext=0)at /test/13.1_dbg/storage/innobase/row/row0ins.cc:3327
      #11 0x00005d4337ce03b0 in row_upd_clust_rec_by_insert (node=0x7027bc028eb8, index=0x702848012328, thr=0x7027bc029240, referenced=false, foreign=false, mtr=0x7828a7558ee8) at /test/13.1_dbg/storage/innobase/row/row0upd.cc:2314
      #12 0x00005d4337cde320 in row_upd_clust_step (node=0x7027bc028eb8, thr=0x7027bc029240) at /test/13.1_dbg/storage/innobase/row/row0upd.cc:2674
      #13 0x00005d4337cdc775 in row_upd (node=0x7027bc028eb8, thr=0x7027bc029240)at /test/13.1_dbg/storage/innobase/row/row0upd.cc:2750
      #14 0x00005d4337cdc530 in row_upd_step (thr=0x7027bc029240)at /test/13.1_dbg/storage/innobase/row/row0upd.cc:2892
      #15 0x00005d4337c78f7d in row_update_for_mysql (prebuilt=0x7027bc028828)at /test/13.1_dbg/storage/innobase/row/row0mysql.cc:1697
      #16 0x00005d4337a7b908 in ha_innobase::update_row (this=0x7027bc0267f0, old_row=0x7027bc027090 "\376\001", new_row=0x7027bc027080 "\377")at /test/13.1_dbg/storage/innobase/handler/ha_innodb.cc:8776
      #17 0x00005d43376a8214 in handler::ha_update_row (this=0x7027bc0267f0, old_data=0x7027bc027090 "\376\001", new_data=0x7027bc027080 "\377")at /test/13.1_dbg/sql/handler.cc:8700
      #18 0x00005d43373d282c in Sql_cmd_update::update_single_table (this=0x7027bc01a0c0, thd=0x7027bc000d60)at /test/13.1_dbg/sql/sql_update.cc:1083
      #19 0x00005d43373d9f5f in Sql_cmd_update::execute_inner (this=0x7027bc01a0c0, thd=0x7027bc000d60) at /test/13.1_dbg/sql/sql_update.cc:3324
      #20 0x00005d433733171d in Sql_cmd_dml::execute (this=0x7027bc01a0c0, thd=0x7027bc000d60) at /test/13.1_dbg/sql/sql_select.cc:35759
      #21 0x00005d4337279546 in mysql_execute_command (thd=0x7027bc000d60, is_called_from_prepared_stmt=false) at /test/13.1_dbg/sql/sql_parse.cc:4493
      #22 0x00005d4337270738 in mysql_parse (thd=0x7027bc000d60, rawbuf=0x7027bc019660 "UPDATE t1 SET a=NULL", length=20, parser_state=0x7828a755b9c0) at /test/13.1_dbg/sql/sql_parse.cc:8005
      #23 0x00005d433726deee in dispatch_command (command=COM_QUERY, thd=0x7027bc000d60, packet=0x7027bc00b871 "UPDATE t1 SET a=NULL", packet_length=20, blocking=true) at /test/13.1_dbg/sql/sql_parse.cc:1903
      #24 0x00005d43372711ba in do_command (thd=0x7027bc000d60, blocking=true)at /test/13.1_dbg/sql/sql_parse.cc:1437
      #25 0x00005d433744cf4e in do_handle_one_connection (connect=0x5d435d783130, put_in_cache=true) at /test/13.1_dbg/sql/sql_connect.cc:1514
      #26 0x00005d433744cd31 in handle_one_connection (arg=0x5d435d783130)at /test/13.1_dbg/sql/sql_connect.cc:1426
      #27 0x00007828c4e9cb84 in start_thread (arg=<optimized out>)at ./nptl/pthread_create.c:447
      #28 0x00007828c4f29ecc in clone3 ()at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:78
      

      Bug Detection Matrix

          Rel    o/d  Build   Commit                                    UniqueID observed             
      CS  10.11  dbg  121026  7aecfef1072045404167edaaba4656edf218a7a8  No bug found                  
      CS  10.11  opt  121026  7aecfef1072045404167edaaba4656edf218a7a8  No bug found                  
      CS  11.4   dbg  121026  fd85202eb2f866bac7117b5a4542b76f438e2780  No bug found                  
      CS  11.4   opt  121026  fd85202eb2f866bac7117b5a4542b76f438e2780  No bug found                  
      CS  11.8   dbg  121026  14362356d14b80242d60dceb9b34f988bbcc9945  No bug found                  
      CS  11.8   opt  121026  14362356d14b80242d60dceb9b34f988bbcc9945  No bug found                  
      CS  12.3   dbg  121026  5e1d303aa6acf34c09309a9d64d750f20fc1921d  No bug found                  
      CS  12.3   opt  121026  5e1d303aa6acf34c09309a9d64d750f20fc1921d  No bug found                  
      CS  13.0   dbg  121026  620a4b5624222048fece7fe1789978ae0675cae2  No bug found                  
      CS  13.0   opt  121026  620a4b5624222048fece7fe1789978ae0675cae2  No bug found                  
      CS  13.2   dbg  121026  cf542109f3389838b4b688b78941797f6a95d51f  size == rec_offs_size(*offsets)|SIGABRT|page_cur_tuple_insert|btr_cur_optimistic_insert|row_ins_clust_index_entry_low|row_ins_clust_index_entry
      CS  13.2   opt  121026  cf542109f3389838b4b688b78941797f6a95d51f  No bug found                  
      ES  10.6   dbg  121026  4cdc4f0b741fd1a3cc3fc34c7dc197a5b12c65cc  No bug found                  
      ES  10.6   opt  121026  4cdc4f0b741fd1a3cc3fc34c7dc197a5b12c65cc  No bug found                  
      ES  11.4   dbg  121026  f1a52e7bb41922f37759b2d6a7d7dbd6b779dd40  No bug found                  
      ES  11.4   opt  121026  f1a52e7bb41922f37759b2d6a7d7dbd6b779dd40  No bug found                  
      ES  11.8   dbg  121026  2b449b705bc9223b003a05bed300873361e5e970  No bug found                  
      ES  11.8   opt  121026  2b449b705bc9223b003a05bed300873361e5e970  No bug found                  
      ES  12.3   dbg  121026  b09ac90250cf897f23f243954754ed88c57f4f31  No bug found                  
      ES  12.3   opt  121026  b09ac90250cf897f23f243954754ed88c57f4f31  No bug found                  
      

      Attachments

        Activity

          People

            thiru Thirunarayanan Balathandayuthapani
            saahil Saahil Alam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0d
                0d
                Logged:
                Time Spent - 1h
                1h

                Git Integration

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