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

Assertion `!m_modifications || !recv_no_log_write' failed in void mtr_t::commit()

    XMLWordPrintable

Details

    Description

      --source include/have_innodb.inc
       
      SET GLOBAL innodb_stats_persistent=0;
      CREATE TABLE t (a INT) ENGINE=INNODB;
      SET GLOBAL innodb_stats_persistent=1;
      ALTER TABLE t ADD COLUMN b INT;
      FLUSH TABLES WITH READ LOCK AND DISABLE checkpoint;
      INSERT INTO t VALUES (1) ;
       
      # Cleanup
      DROP TABLE t;
      

      Leads to:

      CS 11.7.1 54ab281de85f53e4fa7ba07384bed388737681e6 (Debug)

      mariadbd: /test/11.7_dbg/storage/innobase/mtr/mtr0mtr.cc:488: void mtr_t::commit(): Assertion `!m_modifications || !recv_no_log_write' failed.
      

      CS 11.7.1 54ab281de85f53e4fa7ba07384bed388737681e6 (Debug)

      Core was generated by `/test/MD141124-mariadb-11.7.1-linux-x86_64-dbg/bin/mariadbd --no-defaults --max'.
      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 0x1543adcbe700 (LWP 1783843))]
      (gdb) bt
      #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      #1  0x000014f0869cd859 in __GI_abort () at abort.c:79
      #2  0x000014f0869cd729 in __assert_fail_base (fmt=0x14f086b63588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55d1862c0140 "!m_modifications || !recv_no_log_write", file=0x55d1862bef28 "/test/11.7_dbg/storage/innobase/mtr/mtr0mtr.cc", line=488, function=<optimized out>) at assert.c:92
      #3  0x000014f0869defd6 in __GI___assert_fail (assertion=assertion@entry=0x55d1862c0140 "!m_modifications || !recv_no_log_write", file=file@entry=0x55d1862bef28 "/test/11.7_dbg/storage/innobase/mtr/mtr0mtr.cc", line=line@entry=488, function=function@entry=0x55d1862beeba "void mtr_t::commit()") at assert.c:101
      #4  0x000055d185ada279 in mtr_t::commit (this=this@entry=0x14f0771dc5a0) at /test/11.7_dbg/storage/innobase/mtr/mtr0mtr.cc:488
      #5  0x000055d185c2748c in trx_undo_report_row_operation (thr=thr@entry=0x14f064023e38, index=index@entry=0x14f0640a3450, clust_entry=clust_entry@entry=0x14f0640a0760, update=update@entry=0x0, cmpl_info=cmpl_info@entry=0, rec=rec@entry=0x0, offsets=0x0, roll_ptr=0x14f0771dd5e0) at /test/11.7_dbg/storage/innobase/trx/trx0rec.cc:1984
      #6  0x000055d185c7f55d in btr_cur_ins_lock_and_undo (flags=flags@entry=0, cursor=cursor@entry=0x14f0771ddac0, entry=entry@entry=0x14f0640a0760, thr=thr@entry=0x14f064023e38, mtr=mtr@entry=0x14f0771de040, inherit=inherit@entry=0x14f0771dd6b6) at /test/11.7_dbg/storage/innobase/btr/btr0cur.cc:2200
      #7  0x000055d185c85a40 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x14f0771ddac0, offsets=offsets@entry=0x14f0771ddaa8, heap=heap@entry=0x14f0771ddaa0, entry=entry@entry=0x14f0640a0760, rec=rec@entry=0x14f0771ddab8, big_rec=0x14f0771dda98, n_ext=<optimized out>, thr=0x14f064023e38, mtr=0x14f0771de040) at /test/11.7_dbg/storage/innobase/btr/btr0cur.cc:2424
      #8  0x000055d185b6ce0a in row_ins_clust_index_entry_low (flags=flags@entry=0, mode=<optimized out>, mode@entry=BTR_MODIFY_LEAF, index=index@entry=0x14f0640a3450, n_uniq=n_uniq@entry=2, entry=entry@entry=0x14f0640a0760, n_ext=n_ext@entry=0, thr=<optimized out>) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:2882
      #9  0x000055d185b6e71e in row_ins_clust_index_entry (index=index@entry=0x14f0640a3450, entry=entry@entry=0x14f0640a0760, thr=thr@entry=0x14f064023e38, n_ext=n_ext@entry=0) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:3267
      #10 0x000055d185b6fedd in row_ins_index_entry (thr=0x14f064023e38, entry=0x14f0640a0760, index=0x14f0640a3450) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:3402
      #11 row_ins_index_entry_step (thr=0x14f064023e38, node=<optimized out>) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:3568
      #12 row_ins (thr=0x14f064023e38, node=<optimized out>) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:3685
      #13 row_ins_step (thr=thr@entry=0x14f064023e38) at /test/11.7_dbg/storage/innobase/row/row0ins.cc:3814
      #14 0x000055d185b287d6 in que_thr_step (thr=0x14f064023e38) at /test/11.7_dbg/storage/innobase/que/que0que.cc:533
      #15 que_run_threads_low (thr=0x14f064023e38) at /test/11.7_dbg/storage/innobase/que/que0que.cc:610
      #16 que_run_threads (thr=0x14f064023e38) at /test/11.7_dbg/storage/innobase/que/que0que.cc:630
      #17 0x000055d185b28d75 in que_eval_sql (info=info@entry=0x14f0641a95f0, sql=sql@entry=0x55d18630b750 "PROCEDURE TABLE_STATS_SAVE () IS\nBEGIN\nDELETE FROM \"mysql/innodb_table_stats\"\nWHERE\ndatabase_name = :database_name AND\ntable_name = :table_name;\nINSERT INTO \"mysql/innodb_table_stats\"\nVALUES\n(\n:databa"..., trx=trx@entry=0x14f085795680) at /test/11.7_dbg/storage/innobase/que/que0que.cc:669
      #18 0x000055d185d2bbad in dict_stats_exec_sql (pinfo=pinfo@entry=0x14f0641a95f0, sql=sql@entry=0x55d18630b750 "PROCEDURE TABLE_STATS_SAVE () IS\nBEGIN\nDELETE FROM \"mysql/innodb_table_stats\"\nWHERE\ndatabase_name = :database_name AND\ntable_name = :table_name;\nINSERT INTO \"mysql/innodb_table_stats\"\nVALUES\n(\n:databa"..., trx=trx@entry=0x14f085795680) at /test/11.7_dbg/storage/innobase/dict/dict0stats.cc:552
      #19 0x000055d185d30436 in dict_stats_save (table_orig=table_orig@entry=0x14f06417eb10, only_for_index=only_for_index@entry=0x0) at /test/11.7_dbg/storage/innobase/dict/dict0stats.cc:3277
      #20 0x000055d185d3388b in dict_stats_update (table=table@entry=0x14f06417eb10, stats_upd_option=stats_upd_option@entry=DICT_STATS_RECALC_PERSISTENT) at /test/11.7_dbg/storage/innobase/dict/dict0stats.cc:4039
      #21 0x000055d185d33f6c in dict_stats_update (table=table@entry=0x14f06417eb10, stats_upd_option=<optimized out>) at /test/11.7_dbg/storage/innobase/dict/dict0stats.cc:4157
      #22 0x000055d185a191ab in dict_stats_init (table=0x14f06417eb10) at /test/11.7_dbg/storage/innobase/include/dict0stats.inl:165
      #23 ha_innobase::info_low (this=this@entry=0x14f0641017b0, flag=flag@entry=282, is_analyze=is_analyze@entry=false) at /test/11.7_dbg/storage/innobase/handler/ha_innodb.cc:14742
      #24 0x000055d185a19dcc in ha_innobase::info (this=this@entry=0x14f0641017b0, flag=flag@entry=282) at /test/11.7_dbg/storage/innobase/handler/ha_innodb.cc:15019
      #25 0x000055d185a2c5ac in ha_innobase::open (this=<optimized out>, name=<optimized out>) at /test/11.7_dbg/storage/innobase/handler/ha_innodb.cc:6051
      #26 0x000055d1856ef5a3 in handler::ha_open (this=0x14f0641017b0, table_arg=table_arg@entry=0x14f064046898, name=0x14f0640ee010 "./test/t", mode=mode@entry=2, test_if_locked=test_if_locked@entry=18, mem_root=mem_root@entry=0x0, partitions_to_open=0x0) at /test/11.7_dbg/sql/handler.cc:3625
      #27 0x000055d1854f6599 in open_table_from_share (thd=thd@entry=0x14f064000d48, share=share@entry=0x14f0640ed970, alias=alias@entry=0x14f0640168a0, db_stat=db_stat@entry=33, prgflag=prgflag@entry=8, ha_open_flags=18, outparam=0x14f064046898, is_create_table=false, partitions_to_open=0x0) at /test/11.7_dbg/sql/table.cc:4629
      #28 0x000055d185320b9f in open_table (thd=thd@entry=0x14f064000d48, table_list=table_list@entry=0x14f064016858, ot_ctx=ot_ctx@entry=0x14f0771e18b0) at /test/11.7_dbg/sql/sql_base.cc:2239
      #29 0x000055d1853254d7 in open_and_process_table (ot_ctx=0x14f0771e18b0, has_prelocking_list=false, prelocking_strategy=0x14f0771e1aa0, flags=0, counter=0x14f0771e194c, tables=0x14f064016858, thd=0x14f064000d48) at /test/11.7_dbg/sql/sql_base.cc:4177
      #30 open_tables (thd=thd@entry=0x14f064000d48, options=..., start=start@entry=0x14f0771e1938, counter=counter@entry=0x14f0771e194c, flags=flags@entry=0, prelocking_strategy=prelocking_strategy@entry=0x14f0771e1aa0) at /test/11.7_dbg/sql/sql_base.cc:4663
      #31 0x000055d18532647f in open_and_lock_tables (thd=thd@entry=0x14f064000d48, options=..., tables=<optimized out>, tables@entry=0x14f064016858, derived=derived@entry=true, flags=flags@entry=0, prelocking_strategy=prelocking_strategy@entry=0x14f0771e1aa0) at /test/11.7_dbg/sql/sql_base.cc:5632
      #32 0x000055d18536d9fc in open_and_lock_tables (flags=0, derived=true, tables=0x14f064016858, thd=0x14f064000d48) at /test/11.7_dbg/sql/sql_base.h:533
      #33 mysql_insert (thd=thd@entry=0x14f064000d48, table_list=0x14f064016858, fields=..., values_list=..., update_fields=..., update_values=..., duplic=DUP_ERROR, ignore=false, result=0x0) at /test/11.7_dbg/sql/sql_insert.cc:784
      #34 0x000055d1853b132b in mysql_execute_command (thd=thd@entry=0x14f064000d48, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/11.7_dbg/sql/sql_parse.cc:4471
      #35 0x000055d1853a0679 in mysql_parse (thd=thd@entry=0x14f064000d48, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x14f0771e2300) at /test/11.7_dbg/sql/sql_parse.cc:7901
      #36 0x000055d1853b7bb7 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x14f064000d48, packet=packet@entry=0x14f064098a59 "INSERT INTO t (a) VALUES (1) ", packet_length=packet_length@entry=29, blocking=blocking@entry=true) at /test/11.7_dbg/sql/sql_class.h:1656
      #37 0x000055d1853ba40a in do_command (thd=thd@entry=0x14f064000d48, blocking=blocking@entry=true) at /test/11.7_dbg/sql/sql_parse.cc:1416
      #38 0x000055d18553d2e9 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55d188144e18, put_in_cache=put_in_cache@entry=true) at /test/11.7_dbg/sql/sql_connect.cc:1438
      #39 0x000055d18553d7c3 in handle_one_connection (arg=0x55d188144e18) at /test/11.7_dbg/sql/sql_connect.cc:1350
      #40 0x000014f086ef9609 in start_thread (arg=<optimized out>) at pthread_create.c:477
      #41 0x000014f086aca133 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      

      Bug confirmed present in:
      MariaDB: 11.7.1 (dbg)

      Bug (or feature/syntax) confirmed not present in:
      MariaDB: 10.5.28 (dbg), 10.5.28 (opt), 10.6.21 (dbg), 10.6.21 (opt), 10.11.11 (dbg), 10.11.11 (opt), 11.2.6 (dbg), 11.2.6 (opt), 11.4.5 (dbg), 11.4.5 (opt), 11.6.2 (dbg), 11.6.2 (opt), 11.7.1 (opt)

      Attachments

        Issue Links

          Activity

            People

              serg Sergei Golubchik
              ramesh Ramesh Sivaraman
              Votes:
              0 Vote for this issue
              Watchers:
              4 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.