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

Bulk insert operation aborts the server for redundant table

    XMLWordPrintable

Details

    Description

      SET sql_mode='',unique_checks=0,foreign_key_checks=0,GLOBAL innodb_default_row_format=0;
      CREATE TABLE t (a CHAR CHARACTER SET utf8,FULLTEXT KEY(a)) ENGINE=InnoDB;
      INSERT t SELECT * FROM seq_1_to_100000;  # SIGSEGV crash after 0 to 55 seconds
      

      Leads to:

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Optimized)

      InnoDB: Failing assertion: b < &block[srv_sort_buf_size]
      

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Optimized)

      Core was generated by `/test/MD220623-mariadb-11.1.2-linux-x86_64-opt/bin/mariadbd --no-defaults --cor'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23306727179840)
          at ./nptl/pthread_kill.c:44
      [Current thread is 1 (Thread 0x15328531c640 (LWP 4044619))]
      (gdb) bt
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23306727179840) at ./nptl/pthread_kill.c:44
      #1  __pthread_kill_internal (signo=6, threadid=23306727179840) at ./nptl/pthread_kill.c:78
      #2  __GI___pthread_kill (threadid=23306727179840, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
      #3  0x00001532a3042476 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
      #4  0x00001532a30287f3 in __GI_abort () at ./stdlib/abort.c:79
      #5  0x00005615801273ae in ut_dbg_assertion_failed (expr=expr@entry=0x561580d1a22a "b < &block[srv_sort_buf_size]", file=file@entry=0x561580d19be0 "/test/11.1_opt/storage/innobase/row/row0merge.cc", line=line@entry=1184) at /test/11.1_opt/storage/innobase/ut/ut0dbg.cc:60
      #6  0x000056158011904c in row_merge_buf_write (buf=0x153228062f60, block=0x153284fd2000 "", blob_file=0x153228025268) at /test/11.1_opt/storage/innobase/row/row0merge.cc:1184
      #7  0x0000561580839423 in row_merge_bulk_t::write_to_tmp_file (this=this@entry=0x153228025240, index_no=index_no@entry=0) at /test/11.1_opt/storage/innobase/row/row0merge.cc:5190
      #8  0x000056158083985a in row_merge_bulk_t::bulk_insert_buffered (this=0x153228025240, row=@0x153228028e78: {info_bits = 0, n_fields = 5, n_fields_cmp = 1, fields = 0x153228028ea8, n_v_fields = 0, v_fields = 0x0}, ind=<optimized out>, trx=trx@entry=0x1532a0da9b80) at /test/11.1_opt/storage/innobase/row/row0merge.cc:5260
      #9  0x000056158083348c in trx_mod_table_time_t::bulk_insert_buffered (trx=0x1532a0da9b80, index=<optimized out>, entry=<optimized out>, this=<optimized out>) at /test/11.1_opt/storage/innobase/include/trx0trx.h:523
      #10 row_ins_index_entry (thr=0x153228033c10, entry=<optimized out>, index=<optimized out>) at /test/11.1_opt/storage/innobase/row/row0ins.cc:3370
      #11 row_ins_index_entry_step (thr=0x153228033c10, node=0x1532280339e8) at /test/11.1_opt/storage/innobase/row/row0ins.cc:3543
      #12 row_ins (thr=0x153228033c10, node=0x1532280339e8) at /test/11.1_opt/storage/innobase/row/row0ins.cc:3660
      #13 row_ins_step (thr=thr@entry=0x153228033c10) at /test/11.1_opt/storage/innobase/row/row0ins.cc:3789
      #14 0x00005615808435ef in row_insert_for_mysql (mysql_rec=<optimized out>, prebuilt=0x153228033518, ins_mode=ROW_INS_NORMAL) at /test/11.1_opt/storage/innobase/row/row0mysql.cc:1313
      #15 0x000056158079c0ca in ha_innobase::write_row (this=0x1532280179e0, record=0x1532280175c8 "\375\063  ") at /test/11.1_opt/storage/innobase/handler/ha_innodb.cc:7805
      #16 0x000056158050b3f0 in handler::ha_write_row (this=0x1532280179e0, buf=0x1532280175c8 "\375\063  ") at /test/11.1_opt/sql/handler.cc:7798
      #17 0x00005615802608c2 in write_record (thd=0x153228000c68, table=0x153228032688, info=info@entry=0x153228013790, sink=0x0) at /test/11.1_opt/sql/sql_insert.cc:2204
      #18 0x000056158026156e in select_insert::send_data (values=<optimized out>, this=0x153228013740) at /test/11.1_opt/sql/sql_insert.cc:4184
      #19 select_insert::send_data (this=0x153228013740, values=<optimized out>) at /test/11.1_opt/sql/sql_insert.cc:4159
      #20 0x0000561580303524 in select_result_sink::send_data_with_check (u=<optimized out>, sent=<optimized out>, items=@0x153228011260: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x153228011580, last = 0x153228011580, elements = 1}, <No data fields>}, this=<optimized out>) at /test/11.1_opt/sql/sql_class.h:5755
      #21 select_result_sink::send_data_with_check (sent=<optimized out>, u=<optimized out>, items=@0x153228011260: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x153228011580, last = 0x153228011580, elements = 1}, <No data fields>}, this=<optimized out>) at /test/11.1_opt/sql/sql_class.h:5745
      #22 end_send (join=0x153228013800, join_tab=0x153228060088, end_of_records=<optimized out>) at /test/11.1_opt/sql/sql_select.cc:24697
      #23 0x00005615802d608e in evaluate_join_record (join=join@entry=0x153228013800, join_tab=join_tab@entry=0x15322805fc10, error=<optimized out>) at /test/11.1_opt/sql/sql_select.cc:23664
      #24 0x00005615802e87d4 in sub_select (join=0x153228013800, join_tab=0x15322805fc10, end_of_records=false) at /test/11.1_opt/sql/sql_select.cc:23468
      #25 0x000056158031b197 in do_select (procedure=<optimized out>, join=0x153228013800) at /test/11.1_opt/sql/sql_select.cc:22948
      #26 JOIN::exec_inner (this=0x153228013800) at /test/11.1_opt/sql/sql_select.cc:4933
      #27 0x000056158031b5de in JOIN::exec (this=this@entry=0x153228013800) at /test/11.1_opt/sql/sql_select.cc:4710
      #28 0x000056158031966c in mysql_select (thd=0x153228000c68, tables=0x1532280115d8, fields=<optimized out>, conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=<optimized out>, result=0x153228013740, unit=0x153228004cf8, select_lex=0x153228010fa8) at /test/11.1_opt/sql/sql_select.cc:5239
      #29 0x0000561580319dc4 in handle_select (thd=thd@entry=0x153228000c68, lex=lex@entry=0x153228004c18, result=result@entry=0x153228013740, setup_tables_done_option=setup_tables_done_option@entry=35184372088832) at /test/11.1_opt/sql/sql_select.cc:627
      #30 0x00005615802a0edb in mysql_execute_command (thd=0x153228000c68, is_called_from_prepared_stmt=<optimized out>) at /test/11.1_opt/sql/sql_parse.cc:4598
      #31 0x00005615802a14a4 in mysql_parse (rawbuf=<optimized out>, length=<optimized out>, parser_state=<optimized out>, thd=0x153228000c68) at /test/11.1_opt/sql/sql_parse.cc:7769
      #32 mysql_parse (thd=0x153228000c68, rawbuf=<optimized out>, length=<optimized out>, parser_state=<optimized out>) at /test/11.1_opt/sql/sql_parse.cc:7691
      #33 0x00005615802a3af2 in dispatch_command (command=COM_QUERY, thd=0x153228000c68, packet=<optimized out>, packet_length=<optimized out>, blocking=<optimized out>) at /test/11.1_opt/sql/sql_parse.cc:1989
      #34 0x00005615802a5370 in do_command (thd=0x153228000c68, blocking=blocking@entry=true) at /test/11.1_opt/sql/sql_parse.cc:1405
      #35 0x00005615803c0f27 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x56158309acb8, put_in_cache=put_in_cache@entry=true) at /test/11.1_opt/sql/sql_connect.cc:1416
      #36 0x00005615803c11fd in handle_one_connection (arg=0x56158309acb8) at /test/11.1_opt/sql/sql_connect.cc:1318
      #37 0x00001532a3094b43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
      #38 0x00001532a3126a00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
      

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Debug)

      mariadbd: /test/11.1_dbg/storage/innobase/row/row0merge.cc:1174: dberr_t row_merge_buf_write(const row_merge_buf_t*, const merge_file_t*, row_merge_block_t*, merge_file_t*): Assertion `b < &block[srv_sort_buf_size]' failed.
      

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Debug)

      Core was generated by `/test/MD220623-mariadb-11.1.2-linux-x86_64-dbg/bin/mariadbd --no-defaults --cor'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23006060357184)
          at ./nptl/pthread_kill.c:44
      [Current thread is 1 (Thread 0x14ec840e2640 (LWP 4045297))]
      (gdb) bt
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23006060357184) at ./nptl/pthread_kill.c:44
      #1  __pthread_kill_internal (signo=6, threadid=23006060357184) at ./nptl/pthread_kill.c:78
      #2  __GI___pthread_kill (threadid=23006060357184, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
      #3  0x000014ecb0e42476 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
      #4  0x000014ecb0e287f3 in __GI_abort () at ./stdlib/abort.c:79
      #5  0x000014ecb0e2871b in __assert_fail_base (fmt=0x14ecb0fdd150 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55587a1be706 "b < &block[srv_sort_buf_size]", file=0x55587a1becf0 "/test/11.1_dbg/storage/innobase/row/row0merge.cc", line=1174, function=<optimized out>) at ./assert/assert.c:92
      #6  0x000014ecb0e39e96 in __GI___assert_fail (assertion=0x55587a1be706 "b < &block[srv_sort_buf_size]", file=0x55587a1becf0 "/test/11.1_dbg/storage/innobase/row/row0merge.cc", line=1174, function=0x55587a1bfaa0 "dberr_t row_merge_buf_write(const row_merge_buf_t*, const merge_file_t*, row_merge_block_t*, merge_file_t*)") at ./assert/assert.c:101
      #7  0x0000555879b59649 in row_merge_buf_write (buf=buf@entry=0x14ec30090b80, of=of@entry=0x14ec30e72ef0, block=0x14ec72ef9000 "\003\003", blob_file=blob_file@entry=0x14ec30090b48) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:1174
      #8  0x0000555879b5a1cc in row_merge_bulk_t::write_to_tmp_file (this=this@entry=0x14ec30090b20, index_no=index_no@entry=0) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:5190
      #9  0x0000555879b5a67b in row_merge_bulk_t::bulk_insert_buffered (this=0x14ec30090b20, row=@0x14ec30030250: {info_bits = 0, n_fields = 5, n_fields_cmp = 1, fields = 0x14ec30030288, n_v_fields = 0, v_fields = 0x0, magic_n = 65478679}, ind=@0x14ec30024320: {static MAX_N_FIELDS = 1023, id = 23, heap = 0x14ec300241b0, name = {m_name = 0x14ec30024448 "GEN_CLUST_INDEX"}, table = 0x14ec3001fd60, page = 3, merge_threshold = 50, type = 1, trx_id_offset = 6, n_user_defined_cols = 0, nulls_equal = 0, n_uniq = 1, n_def = 5, n_fields = 5, n_nullable = 1, n_core_fields = 5, n_core_null_bytes = 1, static NO_CORE_NULL_BYTES = 255, static DICT_INDEXES_ID = 3, cached = 1, to_be_dropped = 0, online_status = 0, uncommitted = 0, is_dummy = false, in_instant_init = false, magic_n = 76789786, fields = 0x14ec30024458, parser = 0x0, new_vcol_info = 0x0, change_col_info = 0x0, indexes = {prev = 0x0, next = 0x14ec3002c730}, search_info = 0x14ec30024a10, online_log = 0x0, stat_n_diff_key_vals = 0x14ec300244d8, stat_n_sample_sizes = 0x14ec300244e0, stat_n_non_null_key_vals = 0x14ec300244e8, stat_index_size = 1, stat_n_leaf_pages = 1, stats_error_printed = false, rtr_ssn = {m = std::atomic<unsigned int> = { 0 }}, rtr_track = 0x0, trx_id = 15, zip_pad = {mutex = {<std::__mutex_base> = {_M_mutex = {__data = {__lock = 0, __count = 0, __owner = 0, __nusers = 0, __kind = 0, __spins = 0, __elision = 0, __list = {__prev = 0x0, __next = 0x0}}, __size = '\000' <repeats 39 times>, __align = 0}}, <No data fields>}, pad = {m = std::atomic<unsigned long> = { 0 }}, success = 0, failure = 0, n_rounds = 0}, lock = {lock = {writer = {lock = std::atomic<unsigned int> = { 0 }, static HOLDER = 2147483648}, readers = std::atomic<unsigned int> = { 0 }, static WRITER = 2147483648}, recursive = 0, writer = std::atomic<unsigned long> = { 0 }, static FOR_IO = 18446744073709551615, readers_lock = {lock = std::atomic<unsigned int> = { 0 }, static HOLDER = 2147483648}, readers = std::atomic<std::unordered_multiset<unsigned long, std::hash<unsigned long>, std::equal_to<unsigned long>, std::allocator<unsigned long> > *> = { 0x14ec300909c0 }, static RECURSIVE_X = 1, static RECURSIVE_U = 65536, static RECURSIVE_MAX = 65535}}, trx=trx@entry=0x14ecb0303b80) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:5260
      #10 0x0000555879b4b72d in trx_mod_table_time_t::bulk_insert_buffered (trx=0x14ecb0303b80, index=@0x14ec30024320: {static MAX_N_FIELDS = 1023, id = 23, heap = 0x14ec300241b0, name = {m_name = 0x14ec30024448 "GEN_CLUST_INDEX"}, table = 0x14ec3001fd60, page = 3, merge_threshold = 50, type = 1, trx_id_offset = 6, n_user_defined_cols = 0, nulls_equal = 0, n_uniq = 1, n_def = 5, n_fields = 5, n_nullable = 1, n_core_fields = 5, n_core_null_bytes = 1, static NO_CORE_NULL_BYTES = 255, static DICT_INDEXES_ID = 3, cached = 1, to_be_dropped = 0, online_status = 0, uncommitted = 0, is_dummy = false, in_instant_init = false, magic_n = 76789786, fields = 0x14ec30024458, parser = 0x0, new_vcol_info = 0x0, change_col_info = 0x0, indexes = {prev = 0x0, next = 0x14ec3002c730}, search_info = 0x14ec30024a10, online_log = 0x0, stat_n_diff_key_vals = 0x14ec300244d8, stat_n_sample_sizes = 0x14ec300244e0, stat_n_non_null_key_vals = 0x14ec300244e8, stat_index_size = 1, stat_n_leaf_pages = 1, stats_error_printed = false, rtr_ssn = {m = std::atomic<unsigned int> = { 0 }}, rtr_track = 0x0, trx_id = 15, zip_pad = {mutex = {<std::__mutex_base> = {_M_mutex = {__data = {__lock = 0, __count = 0, __owner = 0, __nusers = 0, __kind = 0, __spins = 0, __elision = 0, __list = {__prev = 0x0, __next = 0x0}}, __size = '\000' <repeats 39 times>, __align = 0}}, <No data fields>}, pad = {m = std::atomic<unsigned long> = { 0 }}, success = 0, failure = 0, n_rounds = 0}, lock = {lock = {writer = {lock = std::atomic<unsigned int> = { 0 }, static HOLDER = 2147483648}, readers = std::atomic<unsigned int> = { 0 }, static WRITER = 2147483648}, recursive = 0, writer = std::atomic<unsigned long> = { 0 }, static FOR_IO = 18446744073709551615, readers_lock = {lock = std::atomic<unsigned int> = { 0 }, static HOLDER = 2147483648}, readers = std::atomic<std::unordered_multiset<unsigned long, std::hash<unsigned long>, std::equal_to<unsigned long>, std::allocator<unsigned long> > *> = { 0x14ec300909c0 }, static RECURSIVE_X = 1, static RECURSIVE_U = 65536, static RECURSIVE_MAX = 65535}}, entry=@0x14ec30030250: {info_bits = 0, n_fields = 5, n_fields_cmp = 1, fields = 0x14ec30030288, n_v_fields = 0, v_fields = 0x0, magic_n = 65478679}, this=0x14ec30025d08) at /test/11.1_dbg/storage/innobase/include/trx0trx.h:523
      #11 row_ins_index_entry (thr=0x14ec300414f8, entry=0x14ec30030250, index=0x14ec30024320) at /test/11.1_dbg/storage/innobase/row/row0ins.cc:3370
      #12 row_ins_index_entry_step (thr=0x14ec300414f8, node=0x14ec300412c0) at /test/11.1_dbg/storage/innobase/row/row0ins.cc:3543
      #13 row_ins (thr=0x14ec300414f8, node=0x14ec300412c0) at /test/11.1_dbg/storage/innobase/row/row0ins.cc:3660
      #14 row_ins_step (thr=thr@entry=0x14ec300414f8) at /test/11.1_dbg/storage/innobase/row/row0ins.cc:3789
      #15 0x0000555879b6ce77 in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x14ec30040168 "\375\063  ", '\245' <repeats 12 times>, " \002\004\060\354\024", prebuilt=0x14ec30040de0, ins_mode=ins_mode@entry=ROW_INS_NORMAL) at /test/11.1_dbg/storage/innobase/row/row0mysql.cc:1313
      #16 0x0000555879a1f2e4 in ha_innobase::write_row (this=0x14ec30040580, record=0x14ec30040168 "\375\063  ", '\245' <repeats 12 times>, " \002\004\060\354\024") at /test/11.1_dbg/storage/innobase/handler/ha_innodb.cc:7805
      #17 0x0000555879738acb in handler::ha_write_row (this=0x14ec30040580, buf=0x14ec30040168 "\375\063  ", '\245' <repeats 12 times>, " \002\004\060\354\024") at /test/11.1_dbg/sql/handler.cc:7798
      #18 0x0000555879405d93 in write_record (thd=0x14ec30000d58, table=0x14ec3001f0a8, info=info@entry=0x14ec30016190, sink=0x0) at /test/11.1_dbg/sql/sql_insert.cc:2204
      #19 0x000055587940628e in select_insert::send_data (this=0x14ec30016140, values=<optimized out>) at /test/11.1_dbg/sql/sql_insert.cc:4184
      #20 0x00005558794bd3e0 in select_result_sink::send_data_with_check (sent=<optimized out>, u=<optimized out>, items=@0x14ec30013c60: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x14ec30013f80, last = 0x14ec30013f80, elements = 1}, <No data fields>}, this=<optimized out>) at /test/11.1_dbg/sql/sql_class.h:5755
      #21 end_send (join=0x14ec30016200, join_tab=0x14ec3008b610, end_of_records=<optimized out>) at /test/11.1_dbg/sql/sql_select.cc:24697
      #22 0x000055587948a1d7 in evaluate_join_record (join=join@entry=0x14ec30016200, join_tab=join_tab@entry=0x14ec3008b198, error=error@entry=0) at /test/11.1_dbg/sql/sql_select.cc:23664
      #23 0x00005558794a1b74 in sub_select (join=0x14ec30016200, join_tab=0x14ec3008b198, end_of_records=false) at /test/11.1_dbg/sql/sql_select.cc:23468
      #24 0x00005558794d98ed in do_select (procedure=0x0, join=0x14ec30016200) at /test/11.1_dbg/sql/sql_select.cc:22948
      #25 JOIN::exec_inner (this=this@entry=0x14ec30016200) at /test/11.1_dbg/sql/sql_select.cc:4933
      #26 0x00005558794d9e70 in JOIN::exec (this=this@entry=0x14ec30016200) at /test/11.1_dbg/sql/sql_select.cc:4710
      #27 0x00005558794d7cde in mysql_select (thd=thd@entry=0x14ec30000d58, tables=<optimized out>, fields=@0x14ec30013c60: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x14ec30013f80, last = 0x14ec30013f80, elements = 1}, <No data fields>}, conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=37385761196800, result=0x14ec30016140, unit=0x14ec30004fa8, select_lex=0x14ec300139a8) at /test/11.1_dbg/sql/sql_select.cc:5239
      #28 0x00005558794d8464 in handle_select (thd=thd@entry=0x14ec30000d58, lex=lex@entry=0x14ec30004ec8, result=result@entry=0x14ec30016140, setup_tables_done_option=setup_tables_done_option@entry=35184372088832) at /test/11.1_dbg/sql/sql_select.cc:627
      #29 0x0000555879448f35 in mysql_execute_command (thd=thd@entry=0x14ec30000d58, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/11.1_dbg/sql/sql_parse.cc:4598
      #30 0x000055587944d849 in mysql_parse (thd=thd@entry=0x14ec30000d58, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x14ec840e1240) at /test/11.1_dbg/sql/sql_parse.cc:7769
      #31 0x000055587944f9dd in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x14ec30000d58, packet=packet@entry=0x14ec3000ae69 "INSERT t SELECT * FROM seq_1_to_100000", packet_length=packet_length@entry=38, blocking=blocking@entry=true) at /test/11.1_dbg/sql/sql_class.h:242
      #32 0x00005558794518bc in do_command (thd=0x14ec30000d58, blocking=blocking@entry=true) at /test/11.1_dbg/sql/sql_parse.cc:1405
      #33 0x00005558795a7010 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55587c586a08, put_in_cache=put_in_cache@entry=true) at /test/11.1_dbg/sql/sql_connect.cc:1416
      #34 0x00005558795a726f in handle_one_connection (arg=0x55587c586a08) at /test/11.1_dbg/sql/sql_connect.cc:1318
      #35 0x000014ecb0e94b43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
      #36 0x000014ecb0f26a00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
      

      Bug confirmed present in:
      MariaDB: 10.9.8 (dbg), 10.9.8 (opt), 10.10.6 (dbg), 10.10.6 (opt), 10.11.5 (dbg), 10.11.5 (opt), 11.0.3 (dbg), 11.0.3 (opt), 11.1.2 (dbg), 11.1.2 (opt)

      Some other observations:

      Without setting sql_mode='' we get:

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Debug)

      11.1.2-dbg>INSERT t SELECT * FROM seq_1_to_100000;
      ERROR 1406 (22001): Data too long for column 'a' at row 10
      

      If we individually remove unique_checks=0, foreign_key_checks=0, GLOBAL innodb_default_row_format=0 or CHARACTER SET utf8 (all 4 individually removed/tested) we see this semi-thread hang in all cases:

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Debug)

      11.1.2-dbg>SHOW PROCESSLIST;
      +----+------+-----------+------+---------+------+--------------+----------------------------------------+----------+
      | Id | User | Host      | db   | Command | Time | State        | Info                                   | Progress |
      +----+------+-----------+------+---------+------+--------------+----------------------------------------+----------+
      |  4 | root | localhost | test | Query   |  343 | Sending data | INSERT t SELECT * FROM seq_1_to_100000 |    0.000 |
      |  5 | root | localhost | test | Query   |    0 | starting     | show processlist                       |    0.000 |
      +----+------+-----------+------+---------+------+--------------+----------------------------------------+----------+
      2 rows in set (0.000 sec)
      

      On 10.4 to 10.6 (without removing any clauses) the testcase displays the same behavior as seen in the last point (i.e. a long running thread, the same behavior as removing any of the 4 clauses listed). 10.4 to 10.6 (and possibly the EOL 10.7/10.8) are thus affected as well (semi-thread hang), but in a different way from 10.9+ (SIGSEGV). The SIGSEGV is a regression in 10.9+.

      Removing both the CHARACTER SET utf8 and FULLTEXT allows the query to complete within 2 seconds:

      11.1.2 3883eb63dc5e663558571c33d086c9fd3aa0cf8f (Debug)

      11.1.2-dbg>SET sql_mode='',unique_checks=0,foreign_key_checks=0,GLOBAL innodb_default_row_format=0;
      Query OK, 0 rows affected (0.000 sec)
       
      11.1.2-dbg>CREATE TABLE t (a CHAR,KEY(a)) ENGINE=InnoDB;
      Query OK, 0 rows affected (0.016 sec)
       
      11.1.2-dbg>INSERT t SELECT * FROM seq_1_to_100000;
      Query OK, 100000 rows affected, 65535 warnings (1.843 sec)
      Records: 100000  Duplicates: 0  Warnings: 99991
      

      Removing only the FULLTEXT results in the same crash, so it may not be required/looks unrelated. However, I am leaving it in the original testcase as I noticed some inconsistencies during the testcase reductions.

      Attachments

        Issue Links

          Activity

            People

              thiru Thirunarayanan Balathandayuthapani
              Roel Roel Van de Paar
              Votes:
              0 Vote for this issue
              Watchers:
              4 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.