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

Assertion `(ctx->new_table->fts == __null) == (ctx->new_table->fts_doc_id_index == __null)' failed in commit_cache_norebuild

    XMLWordPrintable

Details

    Description

      SET sql_mode='';
      CREATE TABLE t (FTS_DOC_ID BIGINT UNSIGNED NOT NULL,title CHAR(1),body TEXT);
      INSERT INTO t (title,body)VALUES(0,0), (0,0), (0,0), (0,0), (0,0), (0,0);
      CREATE FULLTEXT INDEX idx1 ON t (title,body);
      CREATE FULLTEXT INDEX idx1 ON t (title,body);
      

      Leads to:

      10.6.0 356c149603285086d964c8a51107be97b981c15c (Debug)

      mysqld: /test/10.6_dbg/storage/innobase/handler/handler0alter.cc:10588: bool commit_cache_norebuild(Alter_inplace_info*, ha_innobase_inplace_ctx*, const TABLE*, const TABLE*, trx_t*): Assertion `(ctx->new_table->fts == __null) == (ctx->new_table->fts_doc_id_index == __null)' failed.
      

      10.6.0 356c149603285086d964c8a51107be97b981c15c (Debug)

      Core was generated by `/test/MD270321-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 0x147160506700 (LWP 21515))]
      (gdb) bt
      #0  __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:56
      #1  0x000056074c5ee343 in my_write_core (sig=sig@entry=6) at /test/10.6_dbg/mysys/stacktrace.c:424
      #2  0x000056074bd8ed1d 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  0x00001471640c4859 in __GI_abort () at abort.c:79
      #6  0x00001471640c4729 in __assert_fail_base (fmt=0x14716425a588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x56074c9b08a0 "(ctx->new_table->fts == __null) == (ctx->new_table->fts_doc_id_index == __null)", file=0x56074c9a6fb8 "/test/10.6_dbg/storage/innobase/handler/handler0alter.cc", line=10588, function=<optimized out>) at assert.c:92
      #7  0x00001471640d5f36 in __GI___assert_fail (assertion=assertion@entry=0x56074c9b08a0 "(ctx->new_table->fts == __null) == (ctx->new_table->fts_doc_id_index == __null)", file=file@entry=0x56074c9a6fb8 "/test/10.6_dbg/storage/innobase/handler/handler0alter.cc", line=line@entry=10588, function=function@entry=0x56074c9b0368 "bool commit_cache_norebuild(Alter_inplace_info*, ha_innobase_inplace_ctx*, const TABLE*, const TABLE*, trx_t*)") at assert.c:101
      #8  0x000056074c1e1c26 in commit_cache_norebuild (ha_alter_info=ha_alter_info@entry=0x147160503230, ctx=ctx@entry=0x147108015678, altered_table=altered_table@entry=0x1471605032e0, table=<optimized out>, trx=trx@entry=0x1471617c12a0) at /test/10.6_dbg/storage/innobase/handler/handler0alter.cc:10588
      #9  0x000056074c1c6651 in ha_innobase::commit_inplace_alter_table (this=0x1471080275b0, altered_table=<optimized out>, ha_alter_info=<optimized out>, commit=<optimized out>) at /test/10.6_dbg/storage/innobase/handler/handler0alter.cc:11225
      #10 0x000056074bd9d109 in handler::ha_commit_inplace_alter_table (this=0x1471080275b0, altered_table=altered_table@entry=0x1471605032e0, ha_alter_info=ha_alter_info@entry=0x147160503230, commit=commit@entry=true) at /test/10.6_dbg/sql/handler.cc:4856
      #11 0x000056074bb961b1 in mysql_inplace_alter_table (thd=thd@entry=0x147108000db8, table_list=0x147108013ca8, table=table@entry=0x147108026cb8, altered_table=altered_table@entry=0x1471605032e0, ha_alter_info=ha_alter_info@entry=0x147160503230, target_mdl_request=target_mdl_request@entry=0x147160503830, alter_ctx=0x147160504390) at /test/10.6_dbg/sql/sql_table.cc:8191
      #12 0x000056074bba9d8a in mysql_alter_table (thd=thd@entry=0x147108000db8, new_db=new_db@entry=0x147108013cc0, new_name=new_name@entry=0x147108013cd0, create_info=create_info@entry=0x147160505000, table_list=<optimized out>, table_list@entry=0x147108013ca8, alter_info=alter_info@entry=0x147160504f10, order_num=0, order=0x0, ignore=false, if_exists=false) at /test/10.6_dbg/sql/sql_table.cc:10779
      #13 0x000056074bacf94e in mysql_execute_command (thd=thd@entry=0x147108000db8) at /test/10.6_dbg/sql/structs.h:563
      #14 0x000056074babb264 in mysql_parse (thd=thd@entry=0x147108000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x147160505410) at /test/10.6_dbg/sql/sql_parse.cc:8004
      #15 0x000056074bac9e6a in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x147108000db8, packet=packet@entry=0x14710800b359 "CREATE FULLTEXT INDEX idx1 ON t (title,body)", packet_length=packet_length@entry=44, blocking=blocking@entry=true) at /test/10.6_dbg/sql/sql_class.h:1331
      #16 0x000056074bacd245 in do_command (thd=0x147108000db8, blocking=blocking@entry=true) at /test/10.6_dbg/sql/sql_parse.cc:1399
      #17 0x000056074bc26452 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x56074fa6d7a8, put_in_cache=put_in_cache@entry=true) at /test/10.6_dbg/sql/sql_connect.cc:1410
      #18 0x000056074bc26a57 in handle_one_connection (arg=arg@entry=0x56074fa6d7a8) at /test/10.6_dbg/sql/sql_connect.cc:1312
      #19 0x000056074c0d0ea5 in pfs_spawn_thread (arg=0x56074f991f08) at /test/10.6_dbg/storage/perfschema/pfs.cc:2201
      #20 0x00001471645d2609 in start_thread (arg=<optimized out>) at pthread_create.c:477
      #21 0x00001471641c1293 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)
      MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.33 (dbg), 5.7.33 (opt), 8.0.23 (dbg), 8.0.23 (opt)

      Attachments

        Activity

          People

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