Uploaded image for project: 'Percona Server'
  1. Percona Server
  2. PS-5117

[PS8QA] Cannot upgrade from PS 5.7 to 8.0 if datadir is bootstrapped with --innodb-encrypt-tables

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 8.0, Not 5.6, Not 5.7
    • Fix Version/s: 8.0.13-3
    • Component/s: None
    • Labels:
      None

      Description

      Testcase

      rm -rf /dev/shm/qa/1001 
      mkdir -p /dev/shm/qa/1001/logs
      mkdir -p /dev/shm/qa/1001/mysqldir/psdata
      
      Attached CNF files
      
      1) DB initialization
      
      /dev/shm/qa/ps57/bin/mysqld --no-defaults --initialize-insecure --basedir=/dev/shm/qa/ps57 --datadir=/dev/shm/qa/1001/mysqldir/psdata --early-plugin-load=keyring_file.so --keyring_file_data=/dev/shm/qa/1001/mysqldir/psdata/keyring --innodb_sys_tablespace_encrypt=ON
      
      2) Startup command
      
      /dev/shm/qa/ps57/bin/mysqld --defaults-file=/dev/shm/qa/1001/ps_lower.cnf --basedir=/dev/shm/qa/ps57 --datadir=/dev/shm/qa/1001/mysqldir/psdata --port=55727 &
      
      3) SQL 
      /dev/shm/qa/ps57/bin/mysql -uroot -S/dev/shm/qa/1001/ps_lower.sock -e"drop database if exists test_encrypt; create database test_encrypt"
      
      sysbench /usr/share/sysbench/oltp_insert.lua --mysql_storage_engine=innodb --table-size=1000 --tables=2 --mysql-db=test_encrypt --mysql-user=root --threads=2 --db-driver=mysql --mysql-socket=/dev/shm/qa/1001/ps_lower.sock prepare
      
      /dev/shm/qa/ps57/bin/mysql -uroot -S/dev/shm/qa/1001/ps_lower.sock -e"ALTER TABLE test_encrypt.sbtest1 TABLESPACE=innodb_system"
      
      4) Shutdown PS-5.7
      
      mysqladmin -uroot -S/dev/shm/qa/1001/ps_lower.sock shutdown
      
      5) Start PS with 8.0 base
      
      /dev/shm/qa/ps80_dbg/bin/mysqld --defaults-file=/dev/shm/qa/1001/ps_upper.cnf --basedir=/dev/shm/qa/ps80_dbg --datadir=/dev/shm/qa/1001/mysqldir/psdata --port=55727 &
      
      6) Check PS live status
      /dev/shm/qa/ps80_dbg/bin/mysqladmin -uroot -S/dev/shm/qa/1001/ps_upper.sock ping
      
      7) Run mysql_upgrade script
      
      /dev/shm/qa/ps80_dbg/bin/mysql_upgrade -uroot -S/dev/shm/qa/1001/ps_upper.sock
      
      
      ramesh@qaserver-05:/dev/shm/qa$ /dev/shm/qa/ps80_dbg/bin/mysql_upgrade -uroot -S/dev/shm/qa/1001/ps_upper.sock
      Checking if update is needed.
      Checking server version.
      Running queries to upgrade MySQL server.
      mysql_upgrade: [ERROR] 13192: Source tablespace is encrypted but target tablespace is not.
      ramesh@qaserver-05:/dev/shm/qa$ 
      

        Smart Checklist

          Attachments

          1. ps_lower.cnf
            0.8 kB
          2. ps_upper.cnf
            0.8 kB

            Issue Links

              Activity

                People

                • Assignee:
                  satya.bodapati Satya Bodapati
                  Reporter:
                  ramesh.sivaraman Ramesh Sivaraman
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  5 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - 0 minutes
                    0m
                    Logged:
                    Time Spent - 39 minutes
                    39m