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

ER_NOT_FORM_FILE or Assertion `!is_set() || (m_status == DA_OK_BULK && is_bulk_op())' failed upon adding partition to a versioned table

    XMLWordPrintable

Details

    Description

      --source include/have_partition.inc
       
      CREATE TABLE t1 (f DATE, t DATE, PERIOD FOR app(f,t)) WITH SYSTEM VERSIONING PARTITION BY SYSTEM_TIME ( PARTITION p1 HISTORY, PARTITION pn CURRENT );
      LOCK TABLE t1 WRITE;
      ALTER TABLE t1 ADD PARTITION (PARTITION p2 HISTORY);
       
      # Cleanup
      DROP TABLE t1;
      

      10.4 debug 18af13b8

      mysqld: /data/src/10.4/sql/sql_error.cc:335: void Diagnostics_area::set_ok_status(ulonglong, ulonglong, const char*): Assertion `!is_set() || (m_status == DA_OK_BULK && is_bulk_op())' failed.
      190904 18:37:13 [ERROR] mysqld got signal 6 ;
       
      #6  0x00007ffb3a2a2e67 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x5640a656a8c8 "!is_set() || (m_status == DA_OK_BULK && is_bulk_op())", file=file@entry=0x5640a656a808 "/data/src/10.4/sql/sql_error.cc", line=line@entry=335, function=function@entry=0x5640a656ac00 <Diagnostics_area::set_ok_status(unsigned long long, unsigned long long, char const*)::__PRETTY_FUNCTION__> "void Diagnostics_area::set_ok_status(ulonglong, ulonglong, const char*)") at assert.c:92
      #7  0x00007ffb3a2a2f12 in __GI___assert_fail (assertion=0x5640a656a8c8 "!is_set() || (m_status == DA_OK_BULK && is_bulk_op())", file=0x5640a656a808 "/data/src/10.4/sql/sql_error.cc", line=335, function=0x5640a656ac00 <Diagnostics_area::set_ok_status(unsigned long long, unsigned long long, char const*)::__PRETTY_FUNCTION__> "void Diagnostics_area::set_ok_status(ulonglong, ulonglong, const char*)") at assert.c:101
      #8  0x00005640a57f2e57 in Diagnostics_area::set_ok_status (this=0x7ffb240064c8, affected_rows=0, last_insert_id=0, message=0x7ffb344704d0 "Records: 0  Duplicates: 0  Warnings: 0") at /data/src/10.4/sql/sql_error.cc:335
      #9  0x00005640a5796548 in my_ok (thd=0x7ffb24000b00, affected_rows_arg=0, id=0, message=0x7ffb344704d0 "Records: 0  Duplicates: 0  Warnings: 0") at /data/src/10.4/sql/sql_class.h:5007
      #10 0x00005640a5d8c244 in fast_end_partition (thd=0x7ffb24000b00, copied=0, deleted=0, table_list=0x7ffb24013230) at /data/src/10.4/sql/sql_partition.cc:4616
      #11 0x00005640a5d93184 in fast_alter_partition_table (thd=0x7ffb24000b00, table=0x7ffb241374c0, alter_info=0x7ffb34472c50, create_info=0x7ffb34472d10, table_list=0x7ffb24013230, db=0x7ffb34472140, table_name=0x7ffb34472150) at /data/src/10.4/sql/sql_partition.cc:7417
      #12 0x00005640a593b817 in mysql_alter_table (thd=0x7ffb24000b00, new_db=0x7ffb240052b8, new_name=0x7ffb240056c0, create_info=0x7ffb34472d10, table_list=0x7ffb24013230, alter_info=0x7ffb34472c50, order_num=0, order=0x0, ignore=false) at /data/src/10.4/sql/sql_table.cc:9837
      #13 0x00005640a59d4485 in Sql_cmd_alter_table::execute (this=0x7ffb24013c58, thd=0x7ffb24000b00) at /data/src/10.4/sql/sql_alter.cc:508
      #14 0x00005640a58521a3 in mysql_execute_command (thd=0x7ffb24000b00) at /data/src/10.4/sql/sql_parse.cc:6099
      #15 0x00005640a58578ec in mysql_parse (thd=0x7ffb24000b00, rawbuf=0x7ffb24013118 "ALTER TABLE t1 ADD PARTITION (PARTITION p2 HISTORY)", length=51, parser_state=0x7ffb34474170, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:7909
      #16 0x00005640a58428ec in dispatch_command (command=COM_QUERY, thd=0x7ffb24000b00, packet=0x7ffb24008321 "ALTER TABLE t1 ADD PARTITION (PARTITION p2 HISTORY)", packet_length=51, is_com_multi=false, is_next_command=false) at /data/src/10.4/sql/sql_parse.cc:1843
      #17 0x00005640a5840f36 in do_command (thd=0x7ffb24000b00) at /data/src/10.4/sql/sql_parse.cc:1360
      #18 0x00005640a59cac47 in do_handle_one_connection (connect=0x5640a94bd140) at /data/src/10.4/sql/sql_connect.cc:1412
      #19 0x00005640a59ca996 in handle_one_connection (arg=0x5640a94bd140) at /data/src/10.4/sql/sql_connect.cc:1316
      #20 0x00005640a6400da3 in pfs_spawn_thread (arg=0x5640a93e13f0) at /data/src/10.4/storage/perfschema/pfs.cc:1862
      #21 0x00007ffb3be174a4 in start_thread (arg=0x7ffb34475700) at pthread_create.c:456
      #22 0x00007ffb3a35fd0f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97
      

      10.4 18af13b8 non-debug

      mysqltest: At line 5: query 'ALTER TABLE t1 ADD PARTITION (PARTITION p2 HISTORY)' failed: 1033: Incorrect information in file: './test/t1.frm'
      

      The problem appeared in 10.4 branch after this merge

      commit db4a27ab738c3ab43173368117583402f995c4f1
      Merge: d1ef02e9592 396da1a7054
      Author: Marko Mäkelä <marko.makela@mariadb.com>
      Date:   Sat Aug 31 06:53:45 2019 +0300
       
          Merge 10.3 into 10.4
      

      but since the test case is not applicable to 10.3, I can't tell which commit caused it.

      Attachments

        Issue Links

          Activity

            People

              midenok Aleksey Midenkov
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              5 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.