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

Assertion `index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()' failed.

Details

    Description

      CREATE TEMPORARY TABLE t1 (c1 INT,c2 VARCHAR(3), INDEX (c1)) ENGINE=InnoDB;
      CREATE TABLE t1 (c1 INT, c2 VARCHAR(3), KEY(c1,c2)) ENGINE=InnoDB;
      DROP TABLE t1;
      SET debug_dbug='+d,do_page_reorganize,do_lock_reverse_page_reorganize';
      INSERT INTO t1 VALUES(1, 1), (2, 2);
      

      Leads to:

      10.6.0 8dd35a2507f8d63ca8df9335d2c6072d5c0e3b86 (Debug)

      mysqld: /test/10.6_dbg/storage/innobase/btr/btr0btr.cc:1425: void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*): Assertion `index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()' failed.
      

      10.6.0 8dd35a2507f8d63ca8df9335d2c6072d5c0e3b86 (Debug)

      Core was generated by `/test/MD160321-mariadb-10.6.0-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __pthread_kill (threadid=<optimized out>, signo=signo@entry=6)
          at ../sysdeps/unix/sysv/linux/pthread_kill.c:56
      [Current thread is 1 (Thread 0x152c1814d700 (LWP 526214))]
      (gdb) bt
      #0  __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:56
      #1  0x0000559256416d0b in my_write_core (sig=sig@entry=6) at /test/10.6_dbg/mysys/stacktrace.c:424
      #2  0x0000559255bae313 in handle_fatal_signal (sig=6) at /test/10.6_dbg/sql/signal_handler.cc:331
      #3  <signal handler called>
      #4  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      #5  0x0000152c1aefb859 in __GI_abort () at abort.c:79
      #6  0x0000152c1aefb729 in __assert_fail_base (fmt=0x152c1b091588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x559256834210 "index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()", file=0x559256833040 "/test/10.6_dbg/storage/innobase/btr/btr0btr.cc", line=1425, function=<optimized out>) at assert.c:92
      #7  0x0000152c1af0cf36 in __GI___assert_fail (assertion=assertion@entry=0x559256834210 "index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()", file=file@entry=0x559256833040 "/test/10.6_dbg/storage/innobase/btr/btr0btr.cc", line=line@entry=1425, function=function@entry=0x559256834090 "void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*)") at assert.c:101
      #8  0x0000559256205936 in btr_page_reorganize_low (cursor=cursor@entry=0x152c1814a438, index=index@entry=0x152bc8028628, mtr=mtr@entry=0x152c1814a9b0) at /test/10.6_dbg/storage/innobase/include/dict0mem.h:1158
      #9  0x00005592562069b5 in btr_page_reorganize (cursor=cursor@entry=0x152c1814a438, index=index@entry=0x152bc8028628, mtr=mtr@entry=0x152c1814a9b0) at /test/10.6_dbg/storage/innobase/btr/btr0btr.cc:1653
      #10 0x000055925622e9b4 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x152c1814a430, offsets=offsets@entry=0x152c1814a388, heap=heap@entry=0x152c1814a378, entry=entry@entry=0x152bc80257b8, rec=rec@entry=0x152c1814a3e0, big_rec=0x152c1814a4d0, n_ext=<optimized out>, thr=0x152bc802a648, mtr=0x152c1814a9b0) at /test/10.6_dbg/storage/innobase/btr/btr0cur.cc:3517
      #11 0x000055925610b70b in row_ins_sec_index_entry_low (flags=flags@entry=0, mode=mode@entry=2, index=index@entry=0x152bc8028628, offsets_heap=<optimized out>, offsets_heap@entry=0x152bc8070078, heap=heap@entry=0x152bc8070518, entry=entry@entry=0x152bc80257b8, trx_id=0, thr=0x152bc802a648) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3135
      #12 0x000055925610bf0e in row_ins_sec_index_entry (index=index@entry=0x152bc8028628, entry=entry@entry=0x152bc80257b8, thr=thr@entry=0x152bc802a648, check_foreign=check_foreign@entry=true) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3336
      #13 0x000055925610db09 in row_ins_index_entry (thr=0x152bc802a648, entry=0x152bc80257b8, index=0x152bc8028628) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3383
      #14 row_ins_index_entry_step (thr=0x152bc802a648, node=0x152bc802a408) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3550
      #15 row_ins (thr=0x152bc802a648, node=0x152bc802a408) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3696
      #16 row_ins_step (thr=thr@entry=0x152bc802a648) at /test/10.6_dbg/storage/innobase/row/row0ins.cc:3838
      #17 0x00005592561322f0 in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x152bc80240f8 "\374\001", prebuilt=0x152bc8029ed8, ins_mode=ROW_INS_NORMAL) at /test/10.6_dbg/storage/innobase/row/row0mysql.cc:1381
      #18 0x0000559255fb55cc in ha_innobase::write_row (this=0x152bc8029680, record=0x152bc80240f8 "\374\001") at /test/10.6_dbg/storage/innobase/handler/ha_innodb.cc:7355
      #19 0x0000559255bc2057 in handler::ha_write_row (this=0x152bc8029680, buf=0x152bc80240f8 "\374\001") at /test/10.6_dbg/sql/handler.cc:7155
      #20 0x00005592558a08c0 in write_record (thd=thd@entry=0x152bc8000db8, table=table@entry=0x152bc8020288, info=info@entry=0x152c1814bd10, sink=sink@entry=0x0) at /test/10.6_dbg/sql/sql_insert.cc:2106
      #21 0x00005592558ac162 in mysql_insert (thd=thd@entry=0x152bc8000db8, table_list=0x152bc8013c90, fields=@0x152bc8005e58: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x559256ec2240 <end_of_list>, last = 0x152bc8005e58, elements = 0}, <No data fields>}, values_list=@0x152bc8005ea0: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x152bc8014968, last = 0x152bc8014af0, elements = 2}, <No data fields>}, update_fields=@0x152bc8005e88: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x559256ec2240 <end_of_list>, last = 0x152bc8005e88, elements = 0}, <No data fields>}, update_values=@0x152bc8005e70: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x559256ec2240 <end_of_list>, last = 0x152bc8005e70, elements = 0}, <No data fields>}, duplic=DUP_ERROR, ignore=false, result=0x0) at /test/10.6_dbg/sql/sql_insert.cc:1099
      #22 0x00005592558f2973 in mysql_execute_command (thd=thd@entry=0x152bc8000db8) at /test/10.6_dbg/sql/sql_parse.cc:4545
      #23 0x00005592558dd876 in mysql_parse (thd=thd@entry=0x152bc8000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x152c1814c410) at /test/10.6_dbg/sql/sql_parse.cc:7998
      #24 0x00005592558ec1e7 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x152bc8000db8, packet=packet@entry=0x152bc800b359 "INSERT INTO t1 VALUES(1, 1), (2, 2)", packet_length=packet_length@entry=35, blocking=blocking@entry=true) at /test/10.6_dbg/sql/sql_class.h:1318
      #25 0x00005592558ef5c1 in do_command (thd=0x152bc8000db8, blocking=blocking@entry=true) at /test/10.6_dbg/sql/sql_parse.cc:1397
      #26 0x0000559255a47178 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x5592591825c8, put_in_cache=put_in_cache@entry=true) at /test/10.6_dbg/sql/sql_connect.cc:1410
      #27 0x0000559255a4777d in handle_one_connection (arg=arg@entry=0x5592591825c8) at /test/10.6_dbg/sql/sql_connect.cc:1312
      #28 0x0000559255ef2a5b in pfs_spawn_thread (arg=0x5592590cad98) at /test/10.6_dbg/storage/perfschema/pfs.cc:2201
      #29 0x0000152c1b409609 in start_thread (arg=<optimized out>) at pthread_create.c:477
      #30 0x0000152c1aff8293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      

      Bug confirmed present in:
      MariaDB: 10.2.38 (dbg), 10.3.29 (dbg), 10.4.19 (dbg), 10.5.10 (dbg), 10.6.0 (dbg)

      Bug (or feature/syntax) confirmed not present in:
      MariaDB: 10.2.38 (opt), 10.3.29 (opt), 10.4.19 (opt), 10.5.10 (opt), 10.6.0 (opt)

      Attachments

        Issue Links

          Activity

            Roel Roel Van de Paar added a comment - - edited

            A whole set of new stacks with this testcase

            SET sql_mode='';
            CREATE TABLE t (c INT KEY,c2 INT,INDEX i (c)) ENGINE=InnoDB;
            SET debug_dbug='+d,do_page_reorganize';
            INSERT INTO t VALUES (1,'a');
            

            Leads to:

            10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug)

            mysqld: /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1314: void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*): Assertion `index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()' failed.
            

            10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug)

            Core was generated by `/test/MD260222-mariadb-10.9.0-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'.
            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 0x154ba813c700 (LWP 1171281))]
            (gdb) bt
            #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
            #1  0x0000154bb419c859 in __GI_abort () at abort.c:79
            #2  0x0000154bb419c729 in __assert_fail_base (fmt=0x154bb4332588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x563e89350ac8 "index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()", file=0x563e8934fe18 "/test/10.9_dbg/storage/innobase/btr/btr0btr.cc", line=1314, function=<optimized out>) at assert.c:92
            #3  0x0000154bb41ae006 in __GI___assert_fail (assertion=assertion@entry=0x563e89350ac8 "index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()", file=file@entry=0x563e8934fe18 "/test/10.9_dbg/storage/innobase/btr/btr0btr.cc", line=line@entry=1314, function=function@entry=0x563e89350940 "void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*)") at assert.c:101
            #4  0x0000563e88cd101d in btr_page_reorganize_low (cursor=cursor@entry=0x154ba81393f8, index=index@entry=0x154b48025778, mtr=mtr@entry=0x154ba8139960) at /test/10.9_dbg/storage/innobase/include/dict0mem.h:1160
            #5  0x0000563e88cd1fb4 in btr_page_reorganize (cursor=cursor@entry=0x154ba81393f8, index=index@entry=0x154b48025778, mtr=mtr@entry=0x154ba8139960) at /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1548
            #6  0x0000563e88cfc7a1 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x154ba81393f0, offsets=offsets@entry=0x154ba8139348, heap=heap@entry=0x154ba8139338, entry=entry@entry=0x154b480246a0, rec=rec@entry=0x154ba81393a0, big_rec=0x154ba8139490, n_ext=<optimized out>, thr=0x154b4802acd8, mtr=0x154ba8139960) at /test/10.9_dbg/storage/innobase/btr/btr0cur.cc:3503
            #7  0x0000563e88be2027 in row_ins_sec_index_entry_low (flags=flags@entry=0, mode=mode@entry=2, index=index@entry=0x154b48025778, offsets_heap=<optimized out>, offsets_heap@entry=0x154b48070a78, heap=heap@entry=0x154b48070f18, entry=entry@entry=0x154b480246a0, trx_id=<optimized out>, thr=<optimized out>) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3130
            #8  0x0000563e88be279a in row_ins_sec_index_entry (index=index@entry=0x154b48025778, entry=entry@entry=0x154b480246a0, thr=thr@entry=0x154b4802acd8, check_foreign=check_foreign@entry=true) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3331
            #9  0x0000563e88be4398 in row_ins_index_entry (thr=0x154b4802acd8, entry=0x154b480246a0, index=0x154b48025778) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3390
            #10 row_ins_index_entry_step (thr=0x154b4802acd8, node=0x154b4802aaa0) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3556
            #11 row_ins (thr=0x154b4802acd8, node=0x154b4802aaa0) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3702
            #12 row_ins_step (thr=thr@entry=0x154b4802acd8) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3848
            #13 0x0000563e88c0885c in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x154b48021748 "\375\001", prebuilt=0x154b4802a578, ins_mode=ROW_INS_NORMAL) at /test/10.9_dbg/storage/innobase/row/row0mysql.cc:1318
            #14 0x0000563e88a83edb in ha_innobase::write_row (this=0x154b48029880, record=0x154b48021748 "\375\001") at /test/10.9_dbg/storage/innobase/handler/ha_innodb.cc:7846
            #15 0x0000563e886dd3e7 in handler::ha_write_row (this=0x154b48029880, buf=0x154b48021748 "\375\001") at /test/10.9_dbg/sql/handler.cc:7522
            #16 0x0000563e883733a0 in write_record (thd=thd@entry=0x154b48000db8, table=table@entry=0x154b48028088, info=info@entry=0x154ba813acd0, sink=sink@entry=0x0) at /test/10.9_dbg/sql/sql_insert.cc:2156
            #17 0x0000563e8837f0f6 in mysql_insert (thd=thd@entry=0x154b48000db8, table_list=0x154b48013ec0, fields=@0x154b48006080: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b48006080, elements = 0}, <No data fields>}, values_list=@0x154b480060c8: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x154b48014b58, last = 0x154b48014b58, elements = 1}, <No data fields>}, update_fields=@0x154b480060b0: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b480060b0, elements = 0}, <No data fields>}, update_values=@0x154b48006098: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b48006098, elements = 0}, <No data fields>}, duplic=DUP_ERROR, ignore=false, result=0x0) at /test/10.9_dbg/sql/sql_insert.cc:1127
            #18 0x0000563e883c5958 in mysql_execute_command (thd=thd@entry=0x154b48000db8, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/10.9_dbg/sql/sql_parse.cc:4562
            #19 0x0000563e883b0343 in mysql_parse (thd=thd@entry=0x154b48000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x154ba813b400) at /test/10.9_dbg/sql/sql_parse.cc:8027
            #20 0x0000563e883befdf in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x154b48000db8, packet=packet@entry=0x154b4800b889 "INSERT INTO t VALUES (1,'a')", packet_length=packet_length@entry=28, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_class.h:1362
            #21 0x0000563e883c2426 in do_command (thd=0x154b48000db8, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_parse.cc:1402
            #22 0x0000563e8853d036 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x563e8b455df8, put_in_cache=put_in_cache@entry=true) at /test/10.9_dbg/sql/sql_connect.cc:1418
            #23 0x0000563e8853d63b in handle_one_connection (arg=arg@entry=0x563e8b455df8) at /test/10.9_dbg/sql/sql_connect.cc:1312
            #24 0x0000563e889c3d23 in pfs_spawn_thread (arg=0x563e8b3695d8) at /test/10.9_dbg/storage/perfschema/pfs.cc:2201
            #25 0x0000154bb46ad609 in start_thread (arg=<optimized out>) at pthread_create.c:477
            #26 0x0000154bb4299163 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
            

            Bug confirmed present in:
            MariaDB: 10.2.44 (dbg), 10.3.35 (dbg), 10.4.25 (dbg), 10.5.16 (dbg), 10.6.8 (dbg), 10.7.4 (dbg), 10.8.3 (dbg), 10.9.0 (dbg)

            Bug (or feature/syntax) confirmed not present in:
            MariaDB: 10.2.44 (opt), 10.3.35 (opt), 10.4.25 (opt), 10.5.16 (opt), 10.6.8 (opt), 10.7.4 (opt), 10.8.3 (opt), 10.9.0 (opt)
            MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.37 (dbg), 5.7.37 (opt), 8.0.28 (dbg), 8.0.28 (opt)

            Roel Roel Van de Paar added a comment - - edited A whole set of new stacks with this testcase SET sql_mode= '' ; CREATE TABLE t (c INT KEY ,c2 INT , INDEX i (c)) ENGINE=InnoDB; SET debug_dbug= '+d,do_page_reorganize' ; INSERT INTO t VALUES (1, 'a' ); Leads to: 10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug) mysqld: /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1314: void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*): Assertion `index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()' failed. 10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug) Core was generated by `/test/MD260222-mariadb-10.9.0-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'. 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 0x154ba813c700 (LWP 1171281))] (gdb) bt #0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50 #1 0x0000154bb419c859 in __GI_abort () at abort.c:79 #2 0x0000154bb419c729 in __assert_fail_base (fmt=0x154bb4332588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x563e89350ac8 "index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()", file=0x563e8934fe18 "/test/10.9_dbg/storage/innobase/btr/btr0btr.cc", line=1314, function=<optimized out>) at assert.c:92 #3 0x0000154bb41ae006 in __GI___assert_fail (assertion=assertion@entry=0x563e89350ac8 "index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()", file=file@entry=0x563e8934fe18 "/test/10.9_dbg/storage/innobase/btr/btr0btr.cc", line=line@entry=1314, function=function@entry=0x563e89350940 "void btr_page_reorganize_low(page_cur_t*, dict_index_t*, mtr_t*)") at assert.c:101 #4 0x0000563e88cd101d in btr_page_reorganize_low (cursor=cursor@entry=0x154ba81393f8, index=index@entry=0x154b48025778, mtr=mtr@entry=0x154ba8139960) at /test/10.9_dbg/storage/innobase/include/dict0mem.h:1160 #5 0x0000563e88cd1fb4 in btr_page_reorganize (cursor=cursor@entry=0x154ba81393f8, index=index@entry=0x154b48025778, mtr=mtr@entry=0x154ba8139960) at /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1548 #6 0x0000563e88cfc7a1 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x154ba81393f0, offsets=offsets@entry=0x154ba8139348, heap=heap@entry=0x154ba8139338, entry=entry@entry=0x154b480246a0, rec=rec@entry=0x154ba81393a0, big_rec=0x154ba8139490, n_ext=<optimized out>, thr=0x154b4802acd8, mtr=0x154ba8139960) at /test/10.9_dbg/storage/innobase/btr/btr0cur.cc:3503 #7 0x0000563e88be2027 in row_ins_sec_index_entry_low (flags=flags@entry=0, mode=mode@entry=2, index=index@entry=0x154b48025778, offsets_heap=<optimized out>, offsets_heap@entry=0x154b48070a78, heap=heap@entry=0x154b48070f18, entry=entry@entry=0x154b480246a0, trx_id=<optimized out>, thr=<optimized out>) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3130 #8 0x0000563e88be279a in row_ins_sec_index_entry (index=index@entry=0x154b48025778, entry=entry@entry=0x154b480246a0, thr=thr@entry=0x154b4802acd8, check_foreign=check_foreign@entry=true) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3331 #9 0x0000563e88be4398 in row_ins_index_entry (thr=0x154b4802acd8, entry=0x154b480246a0, index=0x154b48025778) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3390 #10 row_ins_index_entry_step (thr=0x154b4802acd8, node=0x154b4802aaa0) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3556 #11 row_ins (thr=0x154b4802acd8, node=0x154b4802aaa0) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3702 #12 row_ins_step (thr=thr@entry=0x154b4802acd8) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3848 #13 0x0000563e88c0885c in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x154b48021748 "\375\001", prebuilt=0x154b4802a578, ins_mode=ROW_INS_NORMAL) at /test/10.9_dbg/storage/innobase/row/row0mysql.cc:1318 #14 0x0000563e88a83edb in ha_innobase::write_row (this=0x154b48029880, record=0x154b48021748 "\375\001") at /test/10.9_dbg/storage/innobase/handler/ha_innodb.cc:7846 #15 0x0000563e886dd3e7 in handler::ha_write_row (this=0x154b48029880, buf=0x154b48021748 "\375\001") at /test/10.9_dbg/sql/handler.cc:7522 #16 0x0000563e883733a0 in write_record (thd=thd@entry=0x154b48000db8, table=table@entry=0x154b48028088, info=info@entry=0x154ba813acd0, sink=sink@entry=0x0) at /test/10.9_dbg/sql/sql_insert.cc:2156 #17 0x0000563e8837f0f6 in mysql_insert (thd=thd@entry=0x154b48000db8, table_list=0x154b48013ec0, fields=@0x154b48006080: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b48006080, elements = 0}, <No data fields>}, values_list=@0x154b480060c8: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x154b48014b58, last = 0x154b48014b58, elements = 1}, <No data fields>}, update_fields=@0x154b480060b0: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b480060b0, elements = 0}, <No data fields>}, update_values=@0x154b48006098: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e89a139a0 <end_of_list>, last = 0x154b48006098, elements = 0}, <No data fields>}, duplic=DUP_ERROR, ignore=false, result=0x0) at /test/10.9_dbg/sql/sql_insert.cc:1127 #18 0x0000563e883c5958 in mysql_execute_command (thd=thd@entry=0x154b48000db8, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/10.9_dbg/sql/sql_parse.cc:4562 #19 0x0000563e883b0343 in mysql_parse (thd=thd@entry=0x154b48000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x154ba813b400) at /test/10.9_dbg/sql/sql_parse.cc:8027 #20 0x0000563e883befdf in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x154b48000db8, packet=packet@entry=0x154b4800b889 "INSERT INTO t VALUES (1,'a')", packet_length=packet_length@entry=28, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_class.h:1362 #21 0x0000563e883c2426 in do_command (thd=0x154b48000db8, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_parse.cc:1402 #22 0x0000563e8853d036 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x563e8b455df8, put_in_cache=put_in_cache@entry=true) at /test/10.9_dbg/sql/sql_connect.cc:1418 #23 0x0000563e8853d63b in handle_one_connection (arg=arg@entry=0x563e8b455df8) at /test/10.9_dbg/sql/sql_connect.cc:1312 #24 0x0000563e889c3d23 in pfs_spawn_thread (arg=0x563e8b3695d8) at /test/10.9_dbg/storage/perfschema/pfs.cc:2201 #25 0x0000154bb46ad609 in start_thread (arg=<optimized out>) at pthread_create.c:477 #26 0x0000154bb4299163 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95 Bug confirmed present in: MariaDB: 10.2.44 (dbg), 10.3.35 (dbg), 10.4.25 (dbg), 10.5.16 (dbg), 10.6.8 (dbg), 10.7.4 (dbg), 10.8.3 (dbg), 10.9.0 (dbg) Bug (or feature/syntax) confirmed not present in: MariaDB: 10.2.44 (opt), 10.3.35 (opt), 10.4.25 (opt), 10.5.16 (opt), 10.6.8 (opt), 10.7.4 (opt), 10.8.3 (opt), 10.9.0 (opt) MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.37 (dbg), 5.7.37 (opt), 8.0.28 (dbg), 8.0.28 (opt)

            We need to check whether this bug was fixed after the MDEV-27993 patch.

            Roel Roel Van de Paar added a comment - We need to check whether this bug was fixed after the MDEV-27993 patch.
            Roel Roel Van de Paar added a comment - - edited

            UniqueID's thus far. First one was from the original testcase. Next 4 (i.e. 1-5) are from the second testcase above across versions. Second last one is from testcase below this comment.

            index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            recovery || (index->table)->is_temporary() || !page_is_leaf(temp_page) || !dict_index_is_sec_or_ibuf(index) || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            recovery || index->table->is_temporary() || !page_is_leaf(temp_page) || !!(index)->is_primary() || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            recovery || index->table->is_temporary() || !page_is_leaf(temp_page) || !dict_index_is_sec_or_ibuf(index) || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            (index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0|SIGABRT|page_zip_reorganize|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low
            index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|ibuf_insert_low
            

            Roel Roel Van de Paar added a comment - - edited UniqueID's thus far. First one was from the original testcase. Next 4 (i.e. 1-5) are from the second testcase above across versions. Second last one is from testcase below this comment. index->table->is_temporary() || !page_is_leaf(block->frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low recovery || (index->table)->is_temporary() || !page_is_leaf(temp_page) || !dict_index_is_sec_or_ibuf(index) || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low recovery || index->table->is_temporary() || !page_is_leaf(temp_page) || !!(index)->is_primary() || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low recovery || index->table->is_temporary() || !page_is_leaf(temp_page) || !dict_index_is_sec_or_ibuf(index) || page_get_max_trx_id(page) != 0|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low (index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0|SIGABRT|page_zip_reorganize|btr_page_reorganize|btr_cur_optimistic_insert|row_ins_sec_index_entry_low index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|ibuf_insert_low

            And one more new assertion and stack with this testcase:

            SET sql_mode='';
            CREATE TABLE t (c INT KEY,c2 INT,INDEX i (c2)) ROW_FORMAT=COMPRESSED ENGINE=InnoDB;
            SET debug_dbug='+d,do_page_reorganize,do_lock_reverse_page_reorganize';
            INSERT INTO t VALUES (5,'a');
            

            Leads to:

            10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug)

            mysqld: /test/10.9_dbg/storage/innobase/page/page0zip.cc:4446: bool page_zip_reorganize(buf_block_t*, dict_index_t*, ulint, mtr_t*, bool): Assertion `(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0' failed.
            

            10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug)

            Core was generated by `/test/MD260222-mariadb-10.9.0-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'.
            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 0x149b34070700 (LWP 2843284))]
            (gdb) bt
            #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
            #1  0x0000149b3fcd0859 in __GI_abort () at abort.c:79
            #2  0x0000149b3fcd0729 in __assert_fail_base (fmt=0x149b3fe66588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x563e5a91bcb0 "(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0", file=0x563e5a919d28 "/test/10.9_dbg/storage/innobase/page/page0zip.cc", line=4446, function=<optimized out>) at assert.c:92
            #3  0x0000149b3fce2006 in __GI___assert_fail (assertion=assertion@entry=0x563e5a91bcb0 "(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0", file=file@entry=0x563e5a919d28 "/test/10.9_dbg/storage/innobase/page/page0zip.cc", line=line@entry=4446, function=function@entry=0x563e5a91bc08 "bool page_zip_reorganize(buf_block_t*, dict_index_t*, ulint, mtr_t*, bool)") at assert.c:101
            #4  0x0000563e5a17e8ed in page_zip_reorganize (block=0x149b36509f20, index=index@entry=0x149aac025778, z_level=6, mtr=mtr@entry=0x149b3406d960, restore=restore@entry=true) at /test/10.9_dbg/storage/innobase/include/dict0mem.h:1167
            #5  0x0000563e5a2c6ff0 in btr_page_reorganize (cursor=cursor@entry=0x149b3406d3f8, index=index@entry=0x149aac025778, mtr=mtr@entry=0x149b3406d960) at /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1553
            #6  0x0000563e5a2f17a1 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x149b3406d3f0, offsets=offsets@entry=0x149b3406d348, heap=heap@entry=0x149b3406d338, entry=entry@entry=0x149aac022080, rec=rec@entry=0x149b3406d3a0, big_rec=0x149b3406d490, n_ext=<optimized out>, thr=0x149aac02ad70, mtr=0x149b3406d960) at /test/10.9_dbg/storage/innobase/btr/btr0cur.cc:3503
            #7  0x0000563e5a1d7027 in row_ins_sec_index_entry_low (flags=flags@entry=0, mode=mode@entry=2, index=index@entry=0x149aac025778, offsets_heap=<optimized out>, offsets_heap@entry=0x149aac070b48, heap=heap@entry=0x149aac070fe8, entry=entry@entry=0x149aac022080, trx_id=<optimized out>, thr=<optimized out>) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3130
            #8  0x0000563e5a1d779a in row_ins_sec_index_entry (index=index@entry=0x149aac025778, entry=entry@entry=0x149aac022080, thr=thr@entry=0x149aac02ad70, check_foreign=check_foreign@entry=true) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3331
            #9  0x0000563e5a1d9398 in row_ins_index_entry (thr=0x149aac02ad70, entry=0x149aac022080, index=0x149aac025778) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3390
            #10 row_ins_index_entry_step (thr=0x149aac02ad70, node=0x149aac02ab38) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3556
            #11 row_ins (thr=0x149aac02ad70, node=0x149aac02ab38) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3702
            #12 row_ins_step (thr=thr@entry=0x149aac02ad70) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3848
            #13 0x0000563e5a1fd85c in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x149aac021748 "\375\005", prebuilt=0x149aac02a608, ins_mode=ROW_INS_NORMAL) at /test/10.9_dbg/storage/innobase/row/row0mysql.cc:1318
            #14 0x0000563e5a078edb in ha_innobase::write_row (this=0x149aac029910, record=0x149aac021748 "\375\005") at /test/10.9_dbg/storage/innobase/handler/ha_innodb.cc:7846
            #15 0x0000563e59cd23e7 in handler::ha_write_row (this=0x149aac029910, buf=0x149aac021748 "\375\005") at /test/10.9_dbg/sql/handler.cc:7522
            #16 0x0000563e599683a0 in write_record (thd=thd@entry=0x149aac000db8, table=table@entry=0x149aac028088, info=info@entry=0x149b3406ecd0, sink=sink@entry=0x0) at /test/10.9_dbg/sql/sql_insert.cc:2156
            #17 0x0000563e599740f6 in mysql_insert (thd=thd@entry=0x149aac000db8, table_list=0x149aac013ec0, fields=@0x149aac006080: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac006080, elements = 0}, <No data fields>}, values_list=@0x149aac0060c8: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x149aac014b58, last = 0x149aac014b58, elements = 1}, <No data fields>}, update_fields=@0x149aac0060b0: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac0060b0, elements = 0}, <No data fields>}, update_values=@0x149aac006098: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac006098, elements = 0}, <No data fields>}, duplic=DUP_ERROR, ignore=false, result=0x0) at /test/10.9_dbg/sql/sql_insert.cc:1127
            #18 0x0000563e599ba958 in mysql_execute_command (thd=thd@entry=0x149aac000db8, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/10.9_dbg/sql/sql_parse.cc:4562
            #19 0x0000563e599a5343 in mysql_parse (thd=thd@entry=0x149aac000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x149b3406f400) at /test/10.9_dbg/sql/sql_parse.cc:8027
            #20 0x0000563e599b3fdf in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x149aac000db8, packet=packet@entry=0x149aac00b889 "INSERT INTO t VALUES (5,'a')", packet_length=packet_length@entry=28, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_class.h:1362
            #21 0x0000563e599b7426 in do_command (thd=0x149aac000db8, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_parse.cc:1402
            #22 0x0000563e59b32036 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x563e5c2e3768, put_in_cache=put_in_cache@entry=true) at /test/10.9_dbg/sql/sql_connect.cc:1418
            #23 0x0000563e59b3263b in handle_one_connection (arg=arg@entry=0x563e5c2e3768) at /test/10.9_dbg/sql/sql_connect.cc:1312
            #24 0x0000563e59fb8d23 in pfs_spawn_thread (arg=0x563e5c1f68c8) at /test/10.9_dbg/storage/perfschema/pfs.cc:2201
            #25 0x0000149b401e1609 in start_thread (arg=<optimized out>) at pthread_create.c:477
            #26 0x0000149b3fdcd163 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
            

            Bug confirmed present in:
            MariaDB: 10.2.44 (dbg), 10.3.35 (dbg), 10.4.25 (dbg), 10.5.16 (dbg), 10.6.8 (dbg), 10.7.4 (dbg), 10.8.3 (dbg), 10.9.0 (dbg)

            Bug (or feature/syntax) confirmed not present in:
            MariaDB: 10.2.44 (opt), 10.3.35 (opt), 10.4.25 (opt), 10.5.16 (opt), 10.6.8 (opt), 10.7.4 (opt), 10.8.3 (opt), 10.9.0 (opt)
            MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.37 (dbg), 5.7.37 (opt), 8.0.28 (dbg), 8.0.28 (opt)

            Roel Roel Van de Paar added a comment - And one more new assertion and stack with this testcase: SET sql_mode= '' ; CREATE TABLE t (c INT KEY ,c2 INT , INDEX i (c2)) ROW_FORMAT=COMPRESSED ENGINE=InnoDB; SET debug_dbug= '+d,do_page_reorganize,do_lock_reverse_page_reorganize' ; INSERT INTO t VALUES (5, 'a' ); Leads to: 10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug) mysqld: /test/10.9_dbg/storage/innobase/page/page0zip.cc:4446: bool page_zip_reorganize(buf_block_t*, dict_index_t*, ulint, mtr_t*, bool): Assertion `(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0' failed. 10.9.0 4a2a9c02cd6611ef36bbb735c2b483dbc83580d4 (Debug) Core was generated by `/test/MD260222-mariadb-10.9.0-linux-x86_64-dbg/bin/mysqld --no-defaults --core-'. 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 0x149b34070700 (LWP 2843284))] (gdb) bt #0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50 #1 0x0000149b3fcd0859 in __GI_abort () at abort.c:79 #2 0x0000149b3fcd0729 in __assert_fail_base (fmt=0x149b3fe66588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x563e5a91bcb0 "(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0", file=0x563e5a919d28 "/test/10.9_dbg/storage/innobase/page/page0zip.cc", line=4446, function=<optimized out>) at assert.c:92 #3 0x0000149b3fce2006 in __GI___assert_fail (assertion=assertion@entry=0x563e5a91bcb0 "(index)->is_clust() || !page_is_leaf(temp_page) || page_get_max_trx_id(page) != 0", file=file@entry=0x563e5a919d28 "/test/10.9_dbg/storage/innobase/page/page0zip.cc", line=line@entry=4446, function=function@entry=0x563e5a91bc08 "bool page_zip_reorganize(buf_block_t*, dict_index_t*, ulint, mtr_t*, bool)") at assert.c:101 #4 0x0000563e5a17e8ed in page_zip_reorganize (block=0x149b36509f20, index=index@entry=0x149aac025778, z_level=6, mtr=mtr@entry=0x149b3406d960, restore=restore@entry=true) at /test/10.9_dbg/storage/innobase/include/dict0mem.h:1167 #5 0x0000563e5a2c6ff0 in btr_page_reorganize (cursor=cursor@entry=0x149b3406d3f8, index=index@entry=0x149aac025778, mtr=mtr@entry=0x149b3406d960) at /test/10.9_dbg/storage/innobase/btr/btr0btr.cc:1553 #6 0x0000563e5a2f17a1 in btr_cur_optimistic_insert (flags=flags@entry=0, cursor=cursor@entry=0x149b3406d3f0, offsets=offsets@entry=0x149b3406d348, heap=heap@entry=0x149b3406d338, entry=entry@entry=0x149aac022080, rec=rec@entry=0x149b3406d3a0, big_rec=0x149b3406d490, n_ext=<optimized out>, thr=0x149aac02ad70, mtr=0x149b3406d960) at /test/10.9_dbg/storage/innobase/btr/btr0cur.cc:3503 #7 0x0000563e5a1d7027 in row_ins_sec_index_entry_low (flags=flags@entry=0, mode=mode@entry=2, index=index@entry=0x149aac025778, offsets_heap=<optimized out>, offsets_heap@entry=0x149aac070b48, heap=heap@entry=0x149aac070fe8, entry=entry@entry=0x149aac022080, trx_id=<optimized out>, thr=<optimized out>) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3130 #8 0x0000563e5a1d779a in row_ins_sec_index_entry (index=index@entry=0x149aac025778, entry=entry@entry=0x149aac022080, thr=thr@entry=0x149aac02ad70, check_foreign=check_foreign@entry=true) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3331 #9 0x0000563e5a1d9398 in row_ins_index_entry (thr=0x149aac02ad70, entry=0x149aac022080, index=0x149aac025778) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3390 #10 row_ins_index_entry_step (thr=0x149aac02ad70, node=0x149aac02ab38) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3556 #11 row_ins (thr=0x149aac02ad70, node=0x149aac02ab38) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3702 #12 row_ins_step (thr=thr@entry=0x149aac02ad70) at /test/10.9_dbg/storage/innobase/row/row0ins.cc:3848 #13 0x0000563e5a1fd85c in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x149aac021748 "\375\005", prebuilt=0x149aac02a608, ins_mode=ROW_INS_NORMAL) at /test/10.9_dbg/storage/innobase/row/row0mysql.cc:1318 #14 0x0000563e5a078edb in ha_innobase::write_row (this=0x149aac029910, record=0x149aac021748 "\375\005") at /test/10.9_dbg/storage/innobase/handler/ha_innodb.cc:7846 #15 0x0000563e59cd23e7 in handler::ha_write_row (this=0x149aac029910, buf=0x149aac021748 "\375\005") at /test/10.9_dbg/sql/handler.cc:7522 #16 0x0000563e599683a0 in write_record (thd=thd@entry=0x149aac000db8, table=table@entry=0x149aac028088, info=info@entry=0x149b3406ecd0, sink=sink@entry=0x0) at /test/10.9_dbg/sql/sql_insert.cc:2156 #17 0x0000563e599740f6 in mysql_insert (thd=thd@entry=0x149aac000db8, table_list=0x149aac013ec0, fields=@0x149aac006080: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac006080, elements = 0}, <No data fields>}, values_list=@0x149aac0060c8: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x149aac014b58, last = 0x149aac014b58, elements = 1}, <No data fields>}, update_fields=@0x149aac0060b0: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac0060b0, elements = 0}, <No data fields>}, update_values=@0x149aac006098: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x563e5b0089a0 <end_of_list>, last = 0x149aac006098, elements = 0}, <No data fields>}, duplic=DUP_ERROR, ignore=false, result=0x0) at /test/10.9_dbg/sql/sql_insert.cc:1127 #18 0x0000563e599ba958 in mysql_execute_command (thd=thd@entry=0x149aac000db8, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/10.9_dbg/sql/sql_parse.cc:4562 #19 0x0000563e599a5343 in mysql_parse (thd=thd@entry=0x149aac000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x149b3406f400) at /test/10.9_dbg/sql/sql_parse.cc:8027 #20 0x0000563e599b3fdf in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x149aac000db8, packet=packet@entry=0x149aac00b889 "INSERT INTO t VALUES (5,'a')", packet_length=packet_length@entry=28, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_class.h:1362 #21 0x0000563e599b7426 in do_command (thd=0x149aac000db8, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_parse.cc:1402 #22 0x0000563e59b32036 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x563e5c2e3768, put_in_cache=put_in_cache@entry=true) at /test/10.9_dbg/sql/sql_connect.cc:1418 #23 0x0000563e59b3263b in handle_one_connection (arg=arg@entry=0x563e5c2e3768) at /test/10.9_dbg/sql/sql_connect.cc:1312 #24 0x0000563e59fb8d23 in pfs_spawn_thread (arg=0x563e5c1f68c8) at /test/10.9_dbg/storage/perfschema/pfs.cc:2201 #25 0x0000149b401e1609 in start_thread (arg=<optimized out>) at pthread_create.c:477 #26 0x0000149b3fdcd163 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95 Bug confirmed present in: MariaDB: 10.2.44 (dbg), 10.3.35 (dbg), 10.4.25 (dbg), 10.5.16 (dbg), 10.6.8 (dbg), 10.7.4 (dbg), 10.8.3 (dbg), 10.9.0 (dbg) Bug (or feature/syntax) confirmed not present in: MariaDB: 10.2.44 (opt), 10.3.35 (opt), 10.4.25 (opt), 10.5.16 (opt), 10.6.8 (opt), 10.7.4 (opt), 10.8.3 (opt), 10.9.0 (opt) MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.37 (dbg), 5.7.37 (opt), 8.0.28 (dbg), 8.0.28 (opt)

            The issue could not be reproduced after the MDEV-27993 patch was applied

            ramesh Ramesh Sivaraman added a comment - The issue could not be reproduced after the MDEV-27993 patch was applied

            Adding one previously reduced testcase

            SET GLOBAL innodb_change_buffering=INSERTS;
            SET GLOBAL innodb_change_buffering_debug=1;
            SET debug_dbug='+d,do_page_reorganize,do_lock_reverse_page_reorganize';
            SET unique_checks=0,foreign_key_checks=0,autocommit=0;
            SET GLOBAL innodb_limit_optimistic_insert_debug=2;
            CREATE TABLE t (id INT(1) UNSIGNED,id2 INT(1) UNSIGNED,item CHAR(1),FULLTEXT KEY item (item));
            

            index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|ibuf_insert_low
            

            Roel Roel Van de Paar added a comment - Adding one previously reduced testcase SET GLOBAL innodb_change_buffering=INSERTS; SET GLOBAL innodb_change_buffering_debug=1; SET debug_dbug= '+d,do_page_reorganize,do_lock_reverse_page_reorganize' ; SET unique_checks=0,foreign_key_checks=0,autocommit=0; SET GLOBAL innodb_limit_optimistic_insert_debug=2; CREATE TABLE t (id INT (1) UNSIGNED,id2 INT (1) UNSIGNED,item CHAR (1),FULLTEXT KEY item (item)); index->table->is_temporary() || !page_is_leaf(block->page.frame) || !!(index)->is_primary()|SIGABRT|btr_page_reorganize_low|btr_page_reorganize|btr_cur_optimistic_insert|ibuf_insert_low

            People

              marko Marko Mäkelä
              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.