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

Assertion `cache' failed in fts_init_recover_doc

    XMLWordPrintable

Details

    Description

      Problem found during RQG testing.
      Version: '10.4.3-MariaDB-debug-log'  socket: ...
      mysqld: storage/innobase/fts/fts0fts.cc:7418: ulint fts_init_recover_doc(void*, void*): Assertion `cache' failed.
      190218 21:46:10 [ERROR] mysqld got signal 6 ;
      ...
      Query (0x7f81640144d0): INSERT INTO t4 (col_int, col_text) VALUES ( 3, '1')
      Connection ID (thread ID): 9
      Status: NOT_KILLED
      ...
      #3  <signal handler called>
      #4  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
      #5  0x00007f81b97b0f5d in __GI_abort () at abort.c:90
      #6  0x00007f81b97a6f17 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x561795b6273a "cache", file=file@entry=0x561795b60760 "storage/innobase/fts/fts0fts.cc", line=line@entry=7418, function=function@entry=0x561795b650e0 <fts_init_recover_doc(void*, void*)::__PRETTY_FUNCTION__> "ulint fts_init_recover_doc(void*, void*)") at assert.c:92
      #7  0x00007f81b97a6fc2 in __GI___assert_fail (assertion=0x561795b6273a "cache", file=0x561795b60760 "storage/innobase/fts/fts0fts.cc", line=7418, function=0x561795b650e0 <fts_init_recover_doc(void*, void*)::__PRETTY_FUNCTION__> "ulint fts_init_recover_doc(void*, void*)") at assert.c:101
      #8  0x00005617954f5d06 in fts_init_recover_doc (row=0x7f81641af1c0, user_arg=0x7f816406f2e0) at storage/innobase/fts/fts0fts.cc:7418
      #9  0x00005617953301c6 in fetch_step (thr=0x7f81641b0308) at storage/innobase/row/row0sel.cc:2387
      #10 0x000056179529d1fd in que_thr_step (thr=0x7f81641b0308) at storage/innobase/que/que0que.cc:1026
      #11 0x000056179529d4f4 in que_run_threads_low (thr=0x7f81641b0308) at storage/innobase/que/que0que.cc:1104
      #12 0x000056179529d6e6 in que_run_threads (thr=0x7f81641b0308) at storage/innobase/que/que0que.cc:1144
      #13 0x000056179550a8d8 in fts_eval_sql (trx=0x7f81af400268, graph=0x7f81641b0248) at storage/innobase/fts/fts0sql.cc:238
      #14 0x00005617954ed9a0 in fts_doc_fetch_by_doc_id (get_doc=0x0, doc_id=0, index_to_use=0x7f81641a3bc8, option=2, callback=0x5617954f5c25 <fts_init_recover_doc(void*, void*)>, arg=0x7f816406f2e0) at storage/innobase/fts/fts0fts.cc:3840
      #15 0x00005617954f62ea in fts_init_index (table=0x7f8164053208, has_cache_lock=1) at storage/innobase/fts/fts0fts.cc:7562
      #16 0x00005617954f0106 in fts_init_doc_id (table=0x7f8164053208) at storage/innobase/fts/fts0fts.cc:4908
      #17 0x00005617954ead32 in fts_get_next_doc_id (table=0x7f8164053208, doc_id=0x7f81b411caf8) at storage/innobase/fts/fts0fts.cc:2613
      #18 0x00005617952f597e in row_mysql_convert_row_to_innobase (row=0x7f816407bf08, prebuilt=0x7f816407b838, mysql_rec=0x7f8164055f88 "\374\003", blob_heap=0x7f81b411cb70) at storage/innobase/row/row0mysql.cc:665
      #19 0x00005617952f7868 in row_insert_for_mysql (mysql_rec=0x7f8164055f88 "\374\003", prebuilt=0x7f816407b838, ins_mode=ROW_INS_NORMAL) at storage/innobase/row/row0mysql.cc:1422
      #20 0x00005617951903b3 in ha_innobase::write_row (this=0x7f81640665b0, record=0x7f8164055f88 "\374\003") at storage/innobase/handler/ha_innodb.cc:8065
      #21 0x0000561794f6ecd4 in handler::ha_write_row (this=0x7f81640665b0, buf=0x7f8164055f88 "\374\003") at sql/handler.cc:6497
      #22 0x0000561794be0bc9 in write_record (thd=0x7f8164000ce8, table=0x7f816417b948, info=0x7f81b411d520) at sql/sql_insert.cc:2026
      #23 0x0000561794bddf6b in mysql_insert (thd=0x7f8164000ce8, table_list=0x7f81640145e8, fields=..., values_list=..., update_fields=..., update_values=..., duplic=DUP_ERROR, ignore=false) at sql/sql_insert.cc:1067
      #24 0x0000561794c269dd in mysql_execute_command (thd=0x7f8164000ce8) at sql/sql_parse.cc:4773
      #25 0x0000561794c32a34 in mysql_parse (thd=0x7f8164000ce8, rawbuf=0x7f81640144d0 "INSERT INTO t4 (col_int, col_text) VALUES ( 3, '1')", length=51, parser_state=0x7f81b411e1e0, is_com_multi=false, is_next_command=false) at sql/sql_parse.cc:8141
      #26 0x0000561794c1de40 in dispatch_command (command=COM_QUERY, thd=0x7f8164000ce8, packet=0x7f8164009f39 "INSERT INTO t4 (col_int, col_text) VALUES ( 3, '1') ", packet_length=52, is_com_multi=false, is_next_command=false) at sql/sql_parse.cc:1819
      #27 0x0000561794c1c688 in do_command (thd=0x7f8164000ce8) at sql/sql_parse.cc:1357
      #28 0x0000561794d90745 in do_handle_one_connection (connect=0x561798e1daa8) at sql/sql_connect.cc:1399
      #29 0x0000561794d904a9 in handle_one_connection (arg=0x561798e1daa8) at sql/sql_connect.cc:1302
      #30 0x00005617956c2a4e in pfs_spawn_thread (arg=0x561798e640b8) at storage/perfschema/pfs.cc:1862
      #31 0x00007f81ba6567fc in start_thread (arg=0x7f81b411f700) at pthread_create.c:465
      #32 0x00007f81b988cb5f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      *** all above is taken from test run on 10.4 ***
       
      10.4 commit 19c6a7bbd75d8a72716ecba3aa32d4e9f13daebb 2019-02-18
      10.3 commit e8b6c15010e6fffe17e27c165b8c60b51a8f66a7 2019-02-13
      no replay on 10.2
       
      --source include/have_innodb.inc
       
      --disable_abort_on_error
       
      CREATE TABLE t4 ( col_int INTEGER, col_text TEXT ) ENGINE = InnoDB ;
      INSERT INTO t4 (col_int, col_text) VALUES ( 8, '1') ;
      INSERT INTO t4 (col_int, col_text) VALUES ( 3, '1') ;
      ALTER TABLE t4 ADD FULLTEXT KEY ftidx1 ( col_text ), ADD FULLTEXT KEY ftidx3 ( col_text ) ;
      ALTER TABLE t4 ADD COLUMN col_text_g TEXT GENERATED ALWAYS AS (SUBSTR(col_text,1,499)) VIRTUAL ;
      DELETE FROM t4 WHERE col_int = 8 ;
      ALTER TABLE t4 DROP KEY ftidx1 ;
      INSERT INTO t4 (col_int, col_text) VALUES ( 3, '1') ;
       
      --enable_abort_on_error
      DROP TABLE t4;
      

      Attachments

        1. prt
          54 kB
        2. bs_4.test
          0.6 kB

        Activity

          People

            kevg Eugene Kosov (Inactive)
            mleich Matthias Leich
            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.