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

Assertion `field->type.mbmaxlen > 1' failed in row_merge_buf_redundant_convert

    XMLWordPrintable

    Details

      Description

      --source include/have_innodb.inc
       
      CREATE TABLE t1 (pk INT PRIMARY KEY, a CHAR(8), b CHAR(8) AS (a) VIRTUAL, INDEX(b(3))) CHARACTER SET hp8 ENGINE=InnoDB;
      INSERT INTO t1 (pk,a) VALUES (1,'foo');
      ALTER TABLE t1 ROW_FORMAT=REDUNDANT;
       
      # Cleanup
      DROP TABLE t1;
      

      10.2 900a1475

      mysqld: /data/src/10.2/storage/innobase/row/row0merge.cc:444: void row_merge_buf_redundant_convert(const dfield_t*, dfield_t*, ulint, const page_size_t&, mem_heap_t*): Assertion `field->type.mbmaxlen > 1' failed.
      210127 16:39:53 [ERROR] mysqld got signal 6 ;
       
      #7  0x00007fafeba89f36 in __GI___assert_fail (assertion=0x55e43e66512b "field->type.mbmaxlen > 1", file=0x55e43e664ea8 "/data/src/10.2/storage/innobase/row/row0merge.cc", line=444, function=0x55e43e6650a8 "void row_merge_buf_redundant_convert(const dfield_t*, dfield_t*, ulint, const page_size_t&, mem_heap_t*)") at assert.c:101
      #8  0x000055e43e01dff1 in row_merge_buf_redundant_convert (row_field=0x7faf9003ac00, field=0x7faf9018fe80, len=8, page_size=..., heap=0x7faf9004ab40) at /data/src/10.2/storage/innobase/row/row0merge.cc:444
      #9  0x000055e43e01eb60 in row_merge_buf_add (buf=0x7faf90168640, fts_index=0x0, old_table=0x7faf901733c0, new_table=0x7faf900a1ca0, psort_info=0x0, row=0x7faf9003ab50, ext=0x0, doc_id=0x7fafe5eeceb8, conv_heap=0x7faf9004ab40, err=0x7fafe5eecea4, v_heap=0x7fafe5eeceb0, my_table=0x7faf9009f9a0, trx=0x7fafe6ac2120) at /data/src/10.2/storage/innobase/row/row0merge.cc:696
      #10 0x000055e43e0238b5 in row_merge_read_clustered_index (trx=0x7fafe6ac2120, table=0x7faf9009f9a0, old_table=0x7faf901733c0, new_table=0x7faf900a1ca0, online=false, index=0x7faf9018f330, fts_sort_idx=0x0, psort_info=0x0, files=0x7faf900a1fd0, key_numbers=0x7faf9018f340, n_index=2, add_cols=0x0, add_v=0x0, col_map=0x7faf9018f378, add_autoinc=18446744073709551615, sequence=..., block=0x7fafe4042000 "", skip_pk_sort=true, tmpfd=0x7fafe5eed988, stage=0x7faf900349b0, pct_cost=33.333333333333336, crypt_block=0x0, eval_table=0x7faf9009f9a0) at /data/src/10.2/storage/innobase/row/row0merge.cc:2231
      #11 0x000055e43e02a1fc in row_merge_build_indexes (trx=0x7fafe6ac2120, old_table=0x7faf901733c0, new_table=0x7faf900a1ca0, online=false, indexes=0x7faf9018f330, key_numbers=0x7faf9018f340, n_indexes=2, table=0x7faf9009f9a0, add_cols=0x0, col_map=0x7faf9018f378, add_autoinc=18446744073709551615, sequence=..., skip_pk_sort=true, stage=0x7faf900349b0, add_v=0x0, eval_table=0x7faf9009f9a0) at /data/src/10.2/storage/innobase/row/row0merge.cc:4681
      #12 0x000055e43df3129f in ha_innobase::inplace_alter_table (this=0x7faf90176828, altered_table=0x7faf9009f9a0, ha_alter_info=0x7fafe5eee030) at /data/src/10.2/storage/innobase/handler/handler0alter.cc:6292
      #13 0x000055e43db4535f in handler::ha_inplace_alter_table (this=0x7faf90176828, altered_table=0x7faf9009f9a0, ha_alter_info=0x7fafe5eee030) at /data/src/10.2/sql/handler.h:3792
      #14 0x000055e43db3a7ef in mysql_inplace_alter_table (thd=0x7faf90000d90, table_list=0x7faf900127e8, table=0x7faf90175c20, altered_table=0x7faf9009f9a0, ha_alter_info=0x7fafe5eee030, inplace_supported=HA_ALTER_INPLACE_SHARED_LOCK_AFTER_PREPARE, target_mdl_request=0x7fafe5eee0c0, alter_ctx=0x7fafe5eee670) at /data/src/10.2/sql/sql_table.cc:7458
      #15 0x000055e43db40686 in mysql_alter_table (thd=0x7faf90000d90, new_db=0x7faf90012e00 "test", new_name=0x0, create_info=0x7fafe5eef290, table_list=0x7faf900127e8, alter_info=0x7fafe5eef1e0, order_num=0, order=0x0, ignore=false) at /data/src/10.2/sql/sql_table.cc:9627
      #16 0x000055e43dbbed38 in Sql_cmd_alter_table::execute (this=0x7faf90012e08, thd=0x7faf90000d90) at /data/src/10.2/sql/sql_alter.cc:333
      #17 0x000055e43da6d027 in mysql_execute_command (thd=0x7faf90000d90) at /data/src/10.2/sql/sql_parse.cc:5994
      #18 0x000055e43da7203f in mysql_parse (thd=0x7faf90000d90, rawbuf=0x7faf900126f8 "ALTER TABLE t1 ROW_FORMAT=REDUNDANT", length=35, parser_state=0x7fafe5ef05f0, is_com_multi=false, is_next_command=false) at /data/src/10.2/sql/sql_parse.cc:7763
      #19 0x000055e43da60318 in dispatch_command (command=COM_QUERY, thd=0x7faf90000d90, packet=0x7faf90008b51 "ALTER TABLE t1 ROW_FORMAT=REDUNDANT", packet_length=35, is_com_multi=false, is_next_command=false) at /data/src/10.2/sql/sql_parse.cc:1827
      #20 0x000055e43da5ee13 in do_command (thd=0x7faf90000d90) at /data/src/10.2/sql/sql_parse.cc:1381
      #21 0x000055e43dbb972e in do_handle_one_connection (connect=0x55e4403d4fa0) at /data/src/10.2/sql/sql_connect.cc:1336
      #22 0x000055e43dbb9493 in handle_one_connection (arg=0x55e4403d4fa0) at /data/src/10.2/sql/sql_connect.cc:1241
      #23 0x000055e43e3e19ec in pfs_spawn_thread (arg=0x55e4403b8120) at /data/src/10.2/storage/perfschema/pfs.cc:1869
      #24 0x00007fafebf99609 in start_thread (arg=<optimized out>) at pthread_create.c:477
      #25 0x00007fafebb75293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      

      Reproducible on 10.2+.
      No obvious problem on a non-debug build.

        Attachments

          Activity

            People

            Assignee:
            nikitamalyavin Nikita Malyavin
            Reporter:
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: