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

InnoDB: Assertion failure in file data0type.cc line 67

Details

    Description

      The following SQL query always crashes MariaDB 10.4.8:

      ALTER TABLE `local_db`.`ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT 'Отзыв клиента';
      

      Oct  2 18:02:01 phb mysqld[5224]: 2019-10-02 18:02:01 0x7f2728838700  InnoDB: Assertion failure in file /home/buildbot/buildbot/build/mariadb-10.4.8/storage/innobase/data/data0type.cc line 67
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: Failing assertion: !(prefix_len % mbmaxlen)
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: We intentionally generate a memory trap.
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: Submit a detailed bug report to https://jira.mariadb.org/
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: If you get repeated assertion failures or crashes, even
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: immediately after the mysqld startup, there may be
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: corruption in the InnoDB tablespace. Please refer to
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: https://mariadb.com/kb/en/library/innodb-recovery-modes/
      Oct  2 18:02:01 phb mysqld[5224]: InnoDB: about forcing recovery.
      Oct  2 18:02:01 phb mysqld[5224]: 191002 18:02:01 [ERROR] mysqld got signal 6 ;
      Oct  2 18:02:01 phb mysqld[5224]: This could be because you hit a bug. It is also possible that this binary
      Oct  2 18:02:01 phb mysqld[5224]: or one of the libraries it was linked against is corrupt, improperly built,
      Oct  2 18:02:01 phb mysqld[5224]: or misconfigured. This error can also be caused by malfunctioning hardware.
      Oct  2 18:02:01 phb mysqld[5224]: To report this bug, see https://mariadb.com/kb/en/reporting-bugs
      Oct  2 18:02:01 phb mysqld[5224]: We will try our best to scrape up some info that will hopefully help
      Oct  2 18:02:01 phb mysqld[5224]: diagnose the problem, but since we have already crashed,
      Oct  2 18:02:01 phb mysqld[5224]: something is definitely wrong and this may fail.
      Oct  2 18:02:01 phb mysqld[5224]: Server version: 10.4.8-MariaDB-1:10.4.8+maria~bionic
      Oct  2 18:02:01 phb mysqld[5224]: key_buffer_size=134217728
      Oct  2 18:02:01 phb mysqld[5224]: read_buffer_size=131072
      Oct  2 18:02:01 phb mysqld[5224]: max_used_connections=2
      Oct  2 18:02:01 phb mysqld[5224]: max_threads=153
      Oct  2 18:02:01 phb mysqld[5224]: thread_count=8
      Oct  2 18:02:01 phb mysqld[5224]: It is possible that mysqld could use up to
      Oct  2 18:02:01 phb mysqld[5224]: key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 467735 K  bytes of memory
      Oct  2 18:02:01 phb mysqld[5224]: Hope that's ok; if not, decrease some variables in the equation.
      Oct  2 18:02:01 phb mysqld[5224]: Thread pointer: 0x7f26b0000c08
      Oct  2 18:02:01 phb mysqld[5224]: Attempting backtrace. You can use the following information to find out
      Oct  2 18:02:01 phb mysqld[5224]: where mysqld died. If you see no messages after this, something went
      Oct  2 18:02:01 phb mysqld[5224]: terribly wrong...
      Oct  2 18:02:01 phb mysqld[5224]: stack_bottom = 0x7f2728837dd8 thread_stack 0x49000
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(my_print_stacktrace+0x2e)[0x559b33363fae]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(handle_fatal_signal+0x515)[0x559b32dd9185]
      Oct  2 18:02:01 phb mysqld[5224]: /lib/x86_64-linux-gnu/libpthread.so.0(+0x12890)[0x7f272e040890]
      Oct  2 18:02:01 phb mysqld[5224]: linux/raise.c:51(__GI_raise)[0x7f272c972e97]
      Oct  2 18:02:01 phb mysqld[5224]: stdlib/abort.c:81(__GI_abort)[0x7f272c974801]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0x568a64)[0x559b32ae2a64]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0xbba5b8)[0x559b331345b8]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0xac103f)[0x559b3303b03f]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0xac906f)[0x559b3304306f]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0xacb19a)[0x559b3304519a]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(+0xa1df8a)[0x559b32f97f8a]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z17mysql_alter_tableP3THDPK25st_mysql_const_lex_stringS3_P14HA_CREATE_INFOP10TABLE_LISTP10Alter_infojP8st_orderb+0x2bea)[0x559b32c5de5a]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_ZN19Sql_cmd_alter_table7executeEP3THD+0x3fe)[0x559b32cb339e]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z21mysql_execute_commandP3THD+0x1f2b)[0x559b32bc8a6b]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z11mysql_parseP3THDPcjP12Parser_statebb+0x22a)[0x559b32bcf5fa]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcjbb+0x1689)[0x559b32bd1e29]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z10do_commandP3THD+0x148)[0x559b32bd3418]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(_Z24do_handle_one_connectionP7CONNECT+0x25e)[0x559b32caecce]
      Oct  2 18:02:01 phb mysqld[5224]: /usr/sbin/mysqld(handle_one_connection+0x3d)[0x559b32caed8d]
      Oct  2 18:02:01 phb mysqld[5224]: nptl/pthread_create.c:463(start_thread)[0x7f272e0356db]
      Oct  2 18:02:01 phb mysql-workbench[24677]: gtk_tree_view_unref_tree_helper: assertion 'node != NULL' failed
      Oct  2 18:02:01 phb mysqld[5224]: x86_64/clone.S:97(clone)[0x7f272ca5588f]
      Oct  2 18:02:01 phb mysqld[5224]: Trying to get some variables.
      Oct  2 18:02:01 phb mysqld[5224]: Some pointers may be invalid and cause the dump to abort.
      Oct  2 18:02:01 phb mysqld[5224]: Query (0x7f26b0010000): ALTER TABLE `local_db`.`ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT '                         '
      Oct  2 18:02:01 phb mysqld[5224]: Connection ID (thread ID): 36
      Oct  2 18:02:01 phb mysqld[5224]: Status: NOT_KILLED
      Oct  2 18:02:01 phb mysqld[5224]: Optimizer switch: index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,engine_condition_pushdown=off,index_condition_pushdown=on,derived_merge=on,derived_with_keys=on,firstmatch=on,loosescan=on,materialization=on,in_to_exists=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr=off,mrr_cost_based=off,mrr_sort_keys=off,outer_join_with_cache=on,semijoin_with_cache=on,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=on,table_elimination=on,extended_keys=on,exists_to_in=on,orderby_uses_equalities=on,condition_pushdown_for_derived=on,split_materialized=on,condition_pushdown_for_subquery=on,rowid_filter=on,condition_pushdown_from_having=on
      Oct  2 18:02:01 phb mysqld[5224]: The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
      Oct  2 18:02:01 phb mysqld[5224]: information that should help you find out what is causing the crash.
      Oct  2 18:02:01 phb mysqld[5224]: Writing a core file...
      Oct  2 18:02:01 phb mysqld[5224]: Working directory at /var/lib/mysql
      Oct  2 18:02:01 phb mysqld[5224]: Resource Limits:
      Oct  2 18:02:01 phb mysqld[5224]: Limit                     Soft Limit           Hard Limit           Units
      Oct  2 18:02:01 phb mysqld[5224]: Max cpu time              unlimited            unlimited            seconds
      Oct  2 18:02:01 phb mysqld[5224]: Max file size             unlimited            unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max data size             unlimited            unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max stack size            8388608              unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max core file size        0                    unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max resident set          unlimited            unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max processes             62611                62611                processes
      Oct  2 18:02:01 phb mysqld[5224]: Max open files            16364                16364                files
      Oct  2 18:02:01 phb mysqld[5224]: Max locked memory         16777216             16777216             bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max address space         unlimited            unlimited            bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max file locks            unlimited            unlimited            locks
      Oct  2 18:02:01 phb mysqld[5224]: Max pending signals       62611                62611                signals
      Oct  2 18:02:01 phb mysqld[5224]: Max msgqueue size         819200               819200               bytes
      Oct  2 18:02:01 phb mysqld[5224]: Max nice priority         0                    0
      Oct  2 18:02:01 phb mysqld[5224]: Max realtime priority     0                    0
      Oct  2 18:02:01 phb mysqld[5224]: Max realtime timeout      unlimited            unlimited            us
      Oct  2 18:02:01 phb mysqld[5224]: Core pattern: |/usr/share/apport/apport %p %s %c %d %P
      

      Attachments

        Issue Links

          Activity

            Thanks for the report and test case.
            Same test case, just put together for MTR:

            --source include/have_innodb.inc
             
            CREATE TABLE `ratings_copy` (
              `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
              `ctime` timestamp NOT NULL DEFAULT current_timestamp(),
              `order_id` int(10) unsigned NOT NULL,
              `client_id` int(10) unsigned DEFAULT NULL,
              `courier_id` int(10) unsigned DEFAULT NULL,
              `dispatcher_id` int(10) unsigned DEFAULT NULL,
              `point_id` int(10) unsigned DEFAULT NULL,
              `problem_id` int(10) unsigned DEFAULT NULL,
              `courier_rating` int(11) DEFAULT NULL COMMENT 'Оценка курьера клиентом',
              `courier_rating_comment` text CHARACTER SET utf8 DEFAULT NULL COMMENT 'Отзыв клиента',
              `actual_rating` int(11) DEFAULT NULL,
              `dispatcher_comment` text CHARACTER SET utf8 DEFAULT NULL COMMENT 'Комментарий диспетчера',
              PRIMARY KEY (`id`),
              UNIQUE KEY `problem_id` (`problem_id`),
              KEY `courier_id` (`courier_id`),
              KEY `order_id` (`order_id`),
              KEY `client_id` (`client_id`),
              KEY `idx_dispatcher_comment_courier_rating` (`dispatcher_comment`(1),`courier_rating`),
              KEY `idx_courier_rating_comment_courier_rating` (`courier_rating_comment`(1),`courier_rating`),
              KEY `idx_courier_rating` (`courier_rating`),
              KEY `courier_client` (`courier_id`,`client_id`),
              KEY `client_id_rating_ctime` (`client_id`,`courier_rating`,`ctime`)
            ) ENGINE=InnoDB AUTO_INCREMENT=14807 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='Оценка качества услуг клиентом';
             
            INSERT INTO `ratings_copy` VALUES (14807,'0000-00-00 00:00:00',0,0,0,0,0,0,0,'\"courier_rating_comment\"',0,'\"dispatcher_comment\"'),(14808,'0000-00-00 00:00:00',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14809,'0000-00-00 00:00:00',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14810,'0000-00-00 00:00:00',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14811,'0000-00-00 00:00:00',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14812,'0000-00-00 00:00:00',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
             
            ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT 'Отзыв клиента';
            

            10.4 9b5cdeeb

            mysqld: /data/src/10.4/storage/innobase/data/data0type.cc:64: ulint dtype_get_at_most_n_mbchars(ulint, ulint, ulint, ulint, ulint, const char*): Assertion `!mbmaxlen || !(prefix_len % mbmaxlen)' failed.
            191002 20:23:03 [ERROR] mysqld got signal 6 ;
             
            #7  0x00007f755ad13f12 in __GI___assert_fail (assertion=0x556b440f8d30 "!mbmaxlen || !(prefix_len % mbmaxlen)", file=0x556b440f8ce0 "/data/src/10.4/storage/innobase/data/data0type.cc", line=64, function=0x556b440f8f80 <dtype_get_at_most_n_mbchars(unsigned long, unsigned long, unsigned long, unsigned long, unsigned long, char const*)::__PRETTY_FUNCTION__> "ulint dtype_get_at_most_n_mbchars(ulint, ulint, ulint, ulint, ulint, const char*)") at assert.c:101
            #8  0x0000556b439fae98 in dtype_get_at_most_n_mbchars (prtype=2162940, mbminlen=1, mbmaxlen=3, prefix_len=4, data_len=24, str=0x7f75548ac0b2 "\"courier_rating_comment\"\200") at /data/src/10.4/storage/innobase/data/data0type.cc:64
            #9  0x0000556b4383e638 in row_merge_buf_add (buf=0x7f75081a7a78, fts_index=0x0, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, psort_info=0x0, row=0x7f75083cb130, ext=0x0, doc_id=0x7f75540deca8, conv_heap=0x0, err=0x7f75540dec8c, v_heap=0x7f75540deca0, my_table=0x7f75540e0820, trx=0x7f7554b7d140) at /data/src/10.4/storage/innobase/row/row0merge.cc:743
            #10 0x0000556b4384552d in row_merge_read_clustered_index (trx=0x7f7554b7d140, table=0x7f75540e0820, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, online=true, index=0x7f75081a6d38, fts_sort_idx=0x0, psort_info=0x0, files=0x7f75080be970, key_numbers=0x7f75081a6d40, n_index=1, defaults=0x0, add_v=0x0, col_map=0x0, add_autoinc=18446744073709551615, sequence=..., block=0x7f754c0f4000 "", skip_pk_sort=false, tmpfd=0x7f75540df940, stage=0x7f75081a7990, pct_cost=50, crypt_block=0x0, eval_table=0x7f75540e0820, allow_not_null=false) at /data/src/10.4/storage/innobase/row/row0merge.cc:2362
            #11 0x0000556b4384cd77 in row_merge_build_indexes (trx=0x7f7554b7d140, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, online=true, indexes=0x7f75081a6d38, key_numbers=0x7f75081a6d40, n_indexes=1, table=0x7f75540e0820, defaults=0x0, col_map=0x0, add_autoinc=18446744073709551615, sequence=..., skip_pk_sort=false, stage=0x7f75081a7990, add_v=0x0, eval_table=0x7f75540e0820, allow_not_null=false) at /data/src/10.4/storage/innobase/row/row0merge.cc:4718
            #12 0x0000556b437021ee in ha_innobase::inplace_alter_table (this=0x7f75081a09d8, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790) at /data/src/10.4/storage/innobase/handler/handler0alter.cc:8383
            #13 0x0000556b432070f5 in handler::ha_inplace_alter_table (this=0x7f75081a09d8, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790) at /data/src/10.4/sql/handler.h:4328
            #14 0x0000556b431fb35a in mysql_inplace_alter_table (thd=0x7f7508000b00, table_list=0x7f75080132e8, table=0x7f750819fb70, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790, inplace_supported=HA_ALTER_INPLACE_NOCOPY_NO_LOCK, target_mdl_request=0x7f75540e15f0, alter_ctx=0x7f75540e2120) at /data/src/10.4/sql/sql_table.cc:7715
            #15 0x0000556b432020b4 in mysql_alter_table (thd=0x7f7508000b00, new_db=0x7f75080052b8, new_name=0x7f75080056c0, create_info=0x7f75540e2d10, table_list=0x7f75080132e8, alter_info=0x7f75540e2c50, order_num=0, order=0x0, ignore=false) at /data/src/10.4/sql/sql_table.cc:10086
            #16 0x0000556b432994f3 in Sql_cmd_alter_table::execute (this=0x7f7508013bf8, thd=0x7f7508000b00) at /data/src/10.4/sql/sql_alter.cc:508
            #17 0x0000556b43119983 in mysql_execute_command (thd=0x7f7508000b00) at /data/src/10.4/sql/sql_parse.cc:6094
            #18 0x0000556b4311f057 in mysql_parse (thd=0x7f7508000b00, rawbuf=0x7f7508013128 "ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT '\320\236\321\202\320\267\321\213\320\262 \320\272\320\273\320\270\320\265\320\275\321\202\320\260'", length=110, parser_state=0x7f75540e4170, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:7912
            #19 0x0000556b4310a2ea in dispatch_command (command=COM_QUERY, thd=0x7f7508000b00, packet=0x7f7508137a81 "ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT '\320\236\321\202\320\267\321\213\320\262 \320\272\320\273\320\270\320\265\320\275\321\202\320\260'", packet_length=110, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:1841
            #20 0x0000556b43108977 in do_command (thd=0x7f7508000b00) at /data/src/10.4/sql/sql_parse.cc:1359
            #21 0x0000556b4328fe03 in do_handle_one_connection (connect=0x556b46707fd0) at /data/src/10.4/sql/sql_connect.cc:1412
            #22 0x0000556b4328fb52 in handle_one_connection (arg=0x556b46707fd0) at /data/src/10.4/sql/sql_connect.cc:1316
            #23 0x0000556b43c8ecab in pfs_spawn_thread (arg=0x556b466862b0) at /data/src/10.4/storage/perfschema/pfs.cc:1862
            #24 0x00007f755c8884a4 in start_thread (arg=0x7f75540e5700) at pthread_create.c:456
            #25 0x00007f755add0d0f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97
            

            Also fails on 10.4.7. Didn't check earlier 10.4.
            Not reproducible on 10.3.

            elenst Elena Stepanova added a comment - Thanks for the report and test case. Same test case, just put together for MTR: --source include/have_innodb.inc   CREATE TABLE `ratings_copy` ( `id` int (10) unsigned NOT NULL AUTO_INCREMENT, `ctime` timestamp NOT NULL DEFAULT current_timestamp (), `order_id` int (10) unsigned NOT NULL , `client_id` int (10) unsigned DEFAULT NULL , `courier_id` int (10) unsigned DEFAULT NULL , `dispatcher_id` int (10) unsigned DEFAULT NULL , `point_id` int (10) unsigned DEFAULT NULL , `problem_id` int (10) unsigned DEFAULT NULL , `courier_rating` int (11) DEFAULT NULL COMMENT 'Оценка курьера клиентом' , `courier_rating_comment` text CHARACTER SET utf8 DEFAULT NULL COMMENT 'Отзыв клиента' , `actual_rating` int (11) DEFAULT NULL , `dispatcher_comment` text CHARACTER SET utf8 DEFAULT NULL COMMENT 'Комментарий диспетчера' , PRIMARY KEY (`id`), UNIQUE KEY `problem_id` (`problem_id`), KEY `courier_id` (`courier_id`), KEY `order_id` (`order_id`), KEY `client_id` (`client_id`), KEY `idx_dispatcher_comment_courier_rating` (`dispatcher_comment`(1),`courier_rating`), KEY `idx_courier_rating_comment_courier_rating` (`courier_rating_comment`(1),`courier_rating`), KEY `idx_courier_rating` (`courier_rating`), KEY `courier_client` (`courier_id`,`client_id`), KEY `client_id_rating_ctime` (`client_id`,`courier_rating`,`ctime`) ) ENGINE=InnoDB AUTO_INCREMENT=14807 DEFAULT CHARSET=utf8mb4 COLLATE =utf8mb4_unicode_ci COMMENT= 'Оценка качества услуг клиентом' ;   INSERT INTO `ratings_copy` VALUES (14807, '0000-00-00 00:00:00' ,0,0,0,0,0,0,0, '\"courier_rating_comment\"' ,0, '\"dispatcher_comment\"' ),(14808, '0000-00-00 00:00:00' ,0, NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL ),(14809, '0000-00-00 00:00:00' ,0, NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL ),(14810, '0000-00-00 00:00:00' ,0, NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL ),(14811, '0000-00-00 00:00:00' ,0, NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL ),(14812, '0000-00-00 00:00:00' ,0, NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL , NULL );   ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT 'Отзыв клиента' ; 10.4 9b5cdeeb mysqld: /data/src/10.4/storage/innobase/data/data0type.cc:64: ulint dtype_get_at_most_n_mbchars(ulint, ulint, ulint, ulint, ulint, const char*): Assertion `!mbmaxlen || !(prefix_len % mbmaxlen)' failed. 191002 20:23:03 [ERROR] mysqld got signal 6 ;   #7 0x00007f755ad13f12 in __GI___assert_fail (assertion=0x556b440f8d30 "!mbmaxlen || !(prefix_len % mbmaxlen)", file=0x556b440f8ce0 "/data/src/10.4/storage/innobase/data/data0type.cc", line=64, function=0x556b440f8f80 <dtype_get_at_most_n_mbchars(unsigned long, unsigned long, unsigned long, unsigned long, unsigned long, char const*)::__PRETTY_FUNCTION__> "ulint dtype_get_at_most_n_mbchars(ulint, ulint, ulint, ulint, ulint, const char*)") at assert.c:101 #8 0x0000556b439fae98 in dtype_get_at_most_n_mbchars (prtype=2162940, mbminlen=1, mbmaxlen=3, prefix_len=4, data_len=24, str=0x7f75548ac0b2 "\"courier_rating_comment\"\200") at /data/src/10.4/storage/innobase/data/data0type.cc:64 #9 0x0000556b4383e638 in row_merge_buf_add (buf=0x7f75081a7a78, fts_index=0x0, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, psort_info=0x0, row=0x7f75083cb130, ext=0x0, doc_id=0x7f75540deca8, conv_heap=0x0, err=0x7f75540dec8c, v_heap=0x7f75540deca0, my_table=0x7f75540e0820, trx=0x7f7554b7d140) at /data/src/10.4/storage/innobase/row/row0merge.cc:743 #10 0x0000556b4384552d in row_merge_read_clustered_index (trx=0x7f7554b7d140, table=0x7f75540e0820, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, online=true, index=0x7f75081a6d38, fts_sort_idx=0x0, psort_info=0x0, files=0x7f75080be970, key_numbers=0x7f75081a6d40, n_index=1, defaults=0x0, add_v=0x0, col_map=0x0, add_autoinc=18446744073709551615, sequence=..., block=0x7f754c0f4000 "", skip_pk_sort=false, tmpfd=0x7f75540df940, stage=0x7f75081a7990, pct_cost=50, crypt_block=0x0, eval_table=0x7f75540e0820, allow_not_null=false) at /data/src/10.4/storage/innobase/row/row0merge.cc:2362 #11 0x0000556b4384cd77 in row_merge_build_indexes (trx=0x7f7554b7d140, old_table=0x7f750818d4e8, new_table=0x7f750818d4e8, online=true, indexes=0x7f75081a6d38, key_numbers=0x7f75081a6d40, n_indexes=1, table=0x7f75540e0820, defaults=0x0, col_map=0x0, add_autoinc=18446744073709551615, sequence=..., skip_pk_sort=false, stage=0x7f75081a7990, add_v=0x0, eval_table=0x7f75540e0820, allow_not_null=false) at /data/src/10.4/storage/innobase/row/row0merge.cc:4718 #12 0x0000556b437021ee in ha_innobase::inplace_alter_table (this=0x7f75081a09d8, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790) at /data/src/10.4/storage/innobase/handler/handler0alter.cc:8383 #13 0x0000556b432070f5 in handler::ha_inplace_alter_table (this=0x7f75081a09d8, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790) at /data/src/10.4/sql/handler.h:4328 #14 0x0000556b431fb35a in mysql_inplace_alter_table (thd=0x7f7508000b00, table_list=0x7f75080132e8, table=0x7f750819fb70, altered_table=0x7f75540e0820, ha_alter_info=0x7f75540e0790, inplace_supported=HA_ALTER_INPLACE_NOCOPY_NO_LOCK, target_mdl_request=0x7f75540e15f0, alter_ctx=0x7f75540e2120) at /data/src/10.4/sql/sql_table.cc:7715 #15 0x0000556b432020b4 in mysql_alter_table (thd=0x7f7508000b00, new_db=0x7f75080052b8, new_name=0x7f75080056c0, create_info=0x7f75540e2d10, table_list=0x7f75080132e8, alter_info=0x7f75540e2c50, order_num=0, order=0x0, ignore=false) at /data/src/10.4/sql/sql_table.cc:10086 #16 0x0000556b432994f3 in Sql_cmd_alter_table::execute (this=0x7f7508013bf8, thd=0x7f7508000b00) at /data/src/10.4/sql/sql_alter.cc:508 #17 0x0000556b43119983 in mysql_execute_command (thd=0x7f7508000b00) at /data/src/10.4/sql/sql_parse.cc:6094 #18 0x0000556b4311f057 in mysql_parse (thd=0x7f7508000b00, rawbuf=0x7f7508013128 "ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT '\320\236\321\202\320\267\321\213\320\262 \320\272\320\273\320\270\320\265\320\275\321\202\320\260'", length=110, parser_state=0x7f75540e4170, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:7912 #19 0x0000556b4310a2ea in dispatch_command (command=COM_QUERY, thd=0x7f7508000b00, packet=0x7f7508137a81 "ALTER TABLE `ratings_copy` MODIFY courier_rating_comment text DEFAULT NULL COMMENT '\320\236\321\202\320\267\321\213\320\262 \320\272\320\273\320\270\320\265\320\275\321\202\320\260'", packet_length=110, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:1841 #20 0x0000556b43108977 in do_command (thd=0x7f7508000b00) at /data/src/10.4/sql/sql_parse.cc:1359 #21 0x0000556b4328fe03 in do_handle_one_connection (connect=0x556b46707fd0) at /data/src/10.4/sql/sql_connect.cc:1412 #22 0x0000556b4328fb52 in handle_one_connection (arg=0x556b46707fd0) at /data/src/10.4/sql/sql_connect.cc:1316 #23 0x0000556b43c8ecab in pfs_spawn_thread (arg=0x556b466862b0) at /data/src/10.4/storage/perfschema/pfs.cc:1862 #24 0x00007f755c8884a4 in start_thread (arg=0x7f75540e5700) at pthread_create.c:456 #25 0x00007f755add0d0f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97 Also fails on 10.4.7. Didn't check earlier 10.4. Not reproducible on 10.3.
            alice Alice Sherepa added a comment -

            please check also the test case from MDEV-21214:

            CREATE TABLE t1 ( id varchar(25), KEY id (id(19))) ENGINE=InnoDB DEFAULT CHARSET=utf8;
            INSERT INTO t1 VALUES ('Zone'), ('Zone'),  ('Zone');
             
            ALTER TABLE t1 CONVERT TO CHARACTER SET utf8mb4;
            

            alice Alice Sherepa added a comment - please check also the test case from MDEV-21214 : CREATE TABLE t1 ( id varchar (25), KEY id (id(19))) ENGINE=InnoDB DEFAULT CHARSET=utf8; INSERT INTO t1 VALUES ( 'Zone' ), ( 'Zone' ), ( 'Zone' ); ALTER TABLE t1 CONVERT TO CHARACTER SET utf8mb4;
            BB Silver Asu added a comment -

            We tried this patch with "ALTER TABLE t1 CONVERT TO CHARACTER SET utf8mb4;" and server does not crash anymore.

            BB Silver Asu added a comment - We tried this patch with "ALTER TABLE t1 CONVERT TO CHARACTER SET utf8mb4;" and server does not crash anymore.
            bar Alexander Barkov added a comment - The patches at https://github.com/MariaDB/server/commits/bb-10.4-MDEV-20726-alter-utf8 look OK to push for me.

            I suggested a few additions to the test case. Provided that the amended test works as expected, this is OK to push.

            marko Marko Mäkelä added a comment - I suggested a few additions to the test case. Provided that the amended test works as expected, this is OK to push.
            rogerd007 Roger added a comment -

            This is still broken in 10.4.12, and renders me unable to upgrade a Wordpress installation. Being that's its a showstopper, with a patch available, why has there been no action for months?

            rogerd007 Roger added a comment - This is still broken in 10.4.12, and renders me unable to upgrade a Wordpress installation. Being that's its a showstopper, with a patch available, why has there been no action for months?

            People

              kevg Eugene Kosov (Inactive)
              filb Philipp Bolotov
              Votes:
              3 Vote for this issue
              Watchers:
              16 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.