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

MLOG_FILE_WRITE_CRYPT_DATA fails to set the crypt_data->type for tablespace.

    XMLWordPrintable

Details

    Description

      Problem is that MLOG_FILE_WRITE_CRYPT_DATA redo log fails to apply type for the crypt_data present in the space. While processing the double-write buffe
      pages, page fails to decrypt because fil_space_t doesn't have type.

      The following patch can able to repeat the issue:

      diff --git a/mysql-test/suite/encryption/t/innodb-encryption-alter.test b/mysql-test/suite/encryption/t/innodb-encryption-alter.test
      index e8391d9..8af0bfa 100644
      --- a/mysql-test/suite/encryption/t/innodb-encryption-alter.test
      +++ b/mysql-test/suite/encryption/t/innodb-encryption-alter.test
      @@ -105,6 +105,18 @@ DROP TABLE t2;
       CREATE TABLE t3 (a int not null primary key) engine=innodb ENCRYPTION_KEY_ID=4;
       SHOW WARNINGS;
       
      +--let datadir= `select @@datadir`
      +--let $_server_id= `SELECT @@server_id`
      +--let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect
      +
      +create table t1(f1 int not null, f2 int not null)engine=innodb encrypted=yes;
      +insert into t1 values(1, 2), (2, 3), (4, 5), (5, 6), (7, 8);
      +insert into t1 select * from t1;
      +--source include/kill_mysqld.inc
      +--source include/start_mysqld.inc
      +select * from t1;
      +drop table t1;
      +
      

      It gives the warning messages like:

      10.2 f3e9d9a6e6b2614bf5d57ccf9434c980e4a90424

      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=329] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=337] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=446] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=366] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=450] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=451] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=375] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=384] is corrupted.
      2019-01-17 11:54:52 139736940791616 [Warning] InnoDB: A doublewrite copy of page [page id: space=0, page number=393] is corrupted.
      

      Attachments

        Issue Links

          Activity

            People

              thiru Thirunarayanan Balathandayuthapani
              thiru Thirunarayanan Balathandayuthapani
              Votes:
              0 Vote for this issue
              Watchers:
              1 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.