Details
-
Bug
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Fixed
-
10.1.38
-
None
Description
A regression was introduced in 10.1.38. See the following behavior:
MariaDB [db1]> SET GLOBAL innodb_encrypt_tables=OFF;
|
Query OK, 0 rows affected (0.00 sec)
|
|
MariaDB [db1]> SET SESSION innodb_default_encryption_key_id=2;
|
Query OK, 0 rows affected (0.00 sec)
|
|
MariaDB [db1]> CREATE TABLE unencrypted_tab (id int primary key);
|
ERROR 1005 (HY000): Can't create table `db1`.`unencrypted_tab` (errno: 140 "Wrong create options")
|
MariaDB [db1]> SHOW WARNINGS;
|
+---------+------+--------------------------------------------------------------------------------+
|
| Level | Code | Message |
|
+---------+------+--------------------------------------------------------------------------------+
|
| Warning | 140 | InnoDB: innodb_encrypt_tables=OFF only allows ENCRYPTION_KEY_ID=1 |
|
| Error | 1005 | Can't create table `db1`.`unencrypted_tab` (errno: 140 "Wrong create options") |
|
| Warning | 1030 | Got error 140 "Wrong create options" from storage engine InnoDB |
|
+---------+------+--------------------------------------------------------------------------------+
|
3 rows in set (0.00 sec)
|
This can be worked around by setting innodb_default_encryption_key_id=1 or ENCRYPTED=NO. See the following:
MariaDB [db1]> SET SESSION innodb_default_encryption_key_id=1;
|
Query OK, 0 rows affected (0.00 sec)
|
|
MariaDB [db1]> CREATE TABLE unencrypted_tab (id int primary key);
|
Query OK, 0 rows affected (0.01 sec)
|
|
MariaDB [db1]> DROP TABLE unencrypted_tab;
|
Query OK, 0 rows affected (0.01 sec)
|
|
MariaDB [db1]> SET SESSION innodb_default_encryption_key_id=2;
|
Query OK, 0 rows affected (0.00 sec)
|
|
MariaDB [db1]> CREATE TABLE unencrypted_tab (id int primary key) ENCRYPTED=NO;
|
Query OK, 0 rows affected (0.01 sec)
|
It seems that this was introduced by the following change:
Attachments
Issue Links
- relates to
-
MDEV-19086 Make InnoDB background encryption threads read encryption key ID from FRM
- Open
-
MDEV-17230 encryption_key_id from alter is ignored by encryption threads
- Closed