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

Assertion `bitmap_is_subset(&m_part_info->read_partitions, &m_part_info->lock_partitions)' failed in ha_partition::start_stmt

    XMLWordPrintable

Details

    Description

      --source include/have_partition.inc
       
      create table t1 (pk int auto_increment primary key) partition by hash(pk) partitions 2;
      create trigger tr before insert on t1 for each row set @a=1;
      insert into t1 partition (p1) values (1);
       
      # cleanup
      drop table t1;
      

      10.3 ade89fc8

      mysqld: /data/src/10.3/sql/ha_partition.cc:4082: virtual int ha_partition::start_stmt(THD*, thr_lock_type): Assertion `bitmap_is_subset(&m_part_info->read_partitions, &m_part_info->lock_partitions)' failed.
      200123 22:21:53 [ERROR] mysqld got signal 6 ;
       
      #7  0x00007f4468ee2f12 in __GI___assert_fail (assertion=0x56443d283438 "bitmap_is_subset(&m_part_info->read_partitions, &m_part_info->lock_partitions)", file=0x56443d2826c0 "/data/src/10.3/sql/ha_partition.cc", line=4082, function=0x56443d286a20 <ha_partition::start_stmt(THD*, thr_lock_type)::__PRETTY_FUNCTION__> "virtual int ha_partition::start_stmt(THD*, thr_lock_type)") at assert.c:101
      #8  0x000056443cdfd537 in ha_partition::start_stmt (this=0x7f4448075238, thd=0x7f4448000af0, lock_type=TL_WRITE_CONCURRENT_INSERT) at /data/src/10.3/sql/ha_partition.cc:4081
      #9  0x000056443c226fe8 in check_lock_and_start_stmt (thd=0x7f4448000af0, prelocking_ctx=0x7f4448004900, table_list=0x7f4448012968) at /data/src/10.3/sql/sql_base.cc:4807
      #10 0x000056443c2284b7 in lock_tables (thd=0x7f4448000af0, tables=0x7f4448012968, count=1, flags=0) at /data/src/10.3/sql/sql_base.cc:5324
      #11 0x000056443c22793b in open_and_lock_tables (thd=0x7f4448000af0, options=..., tables=0x7f4448012968, derived=true, flags=0, prelocking_strategy=0x7f4464086a28) at /data/src/10.3/sql/sql_base.cc:5041
      #12 0x000056443c1e4cf9 in open_and_lock_tables (thd=0x7f4448000af0, tables=0x7f4448012968, derived=true, flags=0) at /data/src/10.3/sql/sql_base.h:505
      #13 0x000056443c275639 in mysql_insert (thd=0x7f4448000af0, table_list=0x7f4448012968, fields=..., values_list=..., update_fields=..., update_values=..., duplic=DUP_ERROR, ignore=false) at /data/src/10.3/sql/sql_insert.cc:760
      #14 0x000056443c2ba2b5 in mysql_execute_command (thd=0x7f4448000af0) at /data/src/10.3/sql/sql_parse.cc:4455
      #15 0x000056443c2c5b91 in mysql_parse (thd=0x7f4448000af0, rawbuf=0x7f4448012818 "insert into t1 partition (p1) values (1)", length=40, parser_state=0x7f44640875e0, is_com_multi=false, is_next_command=false) at /data/src/10.3/sql/sql_parse.cc:7818
      #16 0x000056443c2b2705 in dispatch_command (command=COM_QUERY, thd=0x7f4448000af0, packet=0x7f4448123481 "insert into t1 partition (p1) values (1)", packet_length=40, is_com_multi=false, is_next_command=false) at /data/src/10.3/sql/sql_parse.cc:1856
      #17 0x000056443c2b104d in do_command (thd=0x7f4448000af0) at /data/src/10.3/sql/sql_parse.cc:1401
      #18 0x000056443c4289bc in do_handle_one_connection (connect=0x56443ec278a0) at /data/src/10.3/sql/sql_connect.cc:1403
      #19 0x000056443c42871e in handle_one_connection (arg=0x56443ec278a0) at /data/src/10.3/sql/sql_connect.cc:1308
      #20 0x000056443cdd96ee in pfs_spawn_thread (arg=0x56443eb71ea0) at /data/src/10.3/storage/perfschema/pfs.cc:1869
      #21 0x00007f446ae6b4a4 in start_thread (arg=0x7f4464088700) at pthread_create.c:456
      #22 0x00007f4468f9fd0f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97
      

      Reproducible on 10.3-10.5.
      Not reproducible on 10.2.
      No obvious effect on a non-debug build.

      Attachments

        Activity

          People

            sanja Oleksandr Byelkin
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.