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

Index for versioned table gets corrupt after partitioning and DELETE

Details

    Description

      Note: The test is non-deterministic, run with --repeat. It fails for me within 10 attempts, but it can vary on different machines. ASAN or Valgrind don't help.

      --source include/have_partition.inc
       
      CREATE TABLE t1 (pk INT PRIMARY KEY) ENGINE=MyISAM WITH SYSTEM VERSIONING;
      INSERT INTO t1 VALUES (11),(12);
      ALTER TABLE t1 PARTITION BY KEY() PARTITIONS 3;
      DELETE FROM t1 WHERE pk >= 0;
       
      # Cleanup
      DROP TABLE t1;
      

      10.3 9d97e6010eb

      mysqltest: At line 6: query 'DELETE FROM t1 WHERE pk >= 0' failed: 126: Index for table './test/t1#P#p1.MYI' is corrupt; try to repair it
      

      Also reproducible with Aria. Could not reproduce with InnoDB.

      Attachments

        Issue Links

          Activity

            elenst Elena Stepanova created issue -
            elenst Elena Stepanova made changes -
            Field Original Value New Value
            Description _Note: The test is non-deterministic, run with {{--repeat}}. It fails for me within 10 attempts, but it can vary on different machines. ASAN or Valgrind don't help.

            {code:sql}
            --source include/have_partition.inc

            CREATE TABLE t1 (pk INT PRIMARY KEY) ENGINE=MyISAM WITH SYSTEM VERSIONING;
            INSERT INTO t1 VALUES (11),(12);
            ALTER TABLE t1 PARTITION BY KEY() PARTITIONS 3;
            DELETE FROM t1 WHERE pk >= 0;

            # Cleanup
            DROP TABLE t1;
            {code}

            {noformat:title=10.3 9d97e6010eb}
            mysqltest: At line 6: query 'DELETE FROM t1 WHERE pk >= 0' failed: 126: Index for table './test/t1#P#p1.MYI' is corrupt; try to repair it
            {noformat}

            Also reproducible with Aria. Could not reproduce with InnoDB.
            _Note: The test is non-deterministic, run with {{--repeat}}. It fails for me within 10 attempts, but it can vary on different machines. ASAN or Valgrind don't help._

            {code:sql}
            --source include/have_partition.inc

            CREATE TABLE t1 (pk INT PRIMARY KEY) ENGINE=MyISAM WITH SYSTEM VERSIONING;
            INSERT INTO t1 VALUES (11),(12);
            ALTER TABLE t1 PARTITION BY KEY() PARTITIONS 3;
            DELETE FROM t1 WHERE pk >= 0;

            # Cleanup
            DROP TABLE t1;
            {code}

            {noformat:title=10.3 9d97e6010eb}
            mysqltest: At line 6: query 'DELETE FROM t1 WHERE pk >= 0' failed: 126: Index for table './test/t1#P#p1.MYI' is corrupt; try to repair it
            {noformat}

            Also reproducible with Aria. Could not reproduce with InnoDB.
            kevg Eugene Kosov (Inactive) made changes -
            Assignee Sergei Golubchik [ serg ] Eugene Kosov [ kevg ]
            kevg Eugene Kosov (Inactive) made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            kevg Eugene Kosov (Inactive) made changes -
            Assignee Eugene Kosov [ kevg ] Sergei Golubchik [ serg ]
            Status In Progress [ 3 ] In Review [ 10002 ]
            serg Sergei Golubchik made changes -
            Priority Major [ 3 ] Critical [ 2 ]
            serg Sergei Golubchik made changes -
            serg Sergei Golubchik made changes -
            Assignee Sergei Golubchik [ serg ] Eugene Kosov [ kevg ]
            serg Sergei Golubchik made changes -
            Assignee Eugene Kosov [ kevg ] Sergei Golubchik [ serg ]
            serg Sergei Golubchik made changes -
            Assignee Sergei Golubchik [ serg ] Eugene Kosov [ kevg ]
            Status In Review [ 10002 ] Stalled [ 10000 ]
            serg Sergei Golubchik made changes -
            Assignee Eugene Kosov [ kevg ] Sergei Golubchik [ serg ]
            serg Sergei Golubchik made changes -
            Fix Version/s 10.3.7 [ 23005 ]
            Fix Version/s 10.3 [ 22126 ]
            Resolution Fixed [ 1 ]
            Status Stalled [ 10000 ] Closed [ 6 ]
            midenok Aleksey Midenkov made changes -
            midenok Aleksey Midenkov made changes -
            serg Sergei Golubchik made changes -
            Workflow MariaDB v3 [ 85692 ] MariaDB v4 [ 153843 ]

            People

              serg Sergei Golubchik
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              4 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.