summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorJan Lindström <jan.lindstrom@skysql.com>2014-11-27 12:33:27 +0200
committerJan Lindström <jan.lindstrom@skysql.com>2014-11-27 12:33:27 +0200
commit7c0bf419da0a59590692e6079ad9e8c8a0c90b60 (patch)
treedc372e21dc93ed32397e9b481e83c37ac14ce898 /mysql-test
parent5b7500ccb0e788eb1a56bb8abaf0114dacae3fed (diff)
downloadmariadb-git-bb-10.1-encryption.tar.gz
Fixed a bug on status variables and added basic tests for all newbb-10.1-encryption
configuration variables.
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/suite/innodb/r/innodb-page_encryption.result27
-rw-r--r--mysql-test/suite/innodb/r/innodb-page_encryption_compression.result86
-rw-r--r--mysql-test/suite/innodb/t/innodb-page_encryption.test14
-rw-r--r--mysql-test/suite/innodb/t/innodb-page_encryption_compression.test37
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_data_encryption_filekey_basic.result9
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_data_encryption_providername_basic.result9
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_data_encryption_providertype_basic.result11
-rw-r--r--mysql-test/suite/sys_vars/r/innodb_data_encryption_providerurl_basic.result9
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_data_encryption_filekey_basic.test13
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_data_encryption_providername_basic.test13
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_data_encryption_providertype_basic.test15
-rw-r--r--mysql-test/suite/sys_vars/t/innodb_data_encryption_providerurl_basic.test13
12 files changed, 248 insertions, 8 deletions
diff --git a/mysql-test/suite/innodb/r/innodb-page_encryption.result b/mysql-test/suite/innodb/r/innodb-page_encryption.result
index 8a8bec34691..79902d0abe8 100644
--- a/mysql-test/suite/innodb/r/innodb-page_encryption.result
+++ b/mysql-test/suite/innodb/r/innodb-page_encryption.result
@@ -63,6 +63,15 @@ count(*)
select count(*) from innodb_redundant where c1 < 1500000;
count(*)
5000
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value >= 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value >= 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
update innodb_compact set c1 = c1 + 1;
@@ -81,6 +90,15 @@ count(*)
select count(*) from innodb_redundant where c1 < 1500000;
count(*)
5000
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value >= 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value >= 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT;
show create table innodb_compact;
Table Create Table
@@ -151,6 +169,15 @@ count(*)
select count(*) from innodb_redundant where c1 < 1500000;
count(*)
5000
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
drop procedure innodb_insert_proc;
drop table innodb_normal;
drop table innodb_compact;
diff --git a/mysql-test/suite/innodb/r/innodb-page_encryption_compression.result b/mysql-test/suite/innodb/r/innodb-page_encryption_compression.result
index 04e1175eeaa..a9494795814 100644
--- a/mysql-test/suite/innodb/r/innodb-page_encryption_compression.result
+++ b/mysql-test/suite/innodb/r/innodb-page_encryption_compression.result
@@ -1,9 +1,17 @@
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
set global innodb_compression_algorithm = 1;
-create table innodb_normal(c1 bigint not null, b char(200)) engine=innodb;
+create table innodb_normal(c1 bigint not null, b char(200)) engine=innodb page_compressed=1;
create table innodb_compact(c1 bigint not null, b char(200)) engine=innodb row_format=compact page_encryption=1 page_encryption_key=1 page_compressed=1;
-create table innodb_dynamic(c1 bigint not null, b char(200)) engine=innodb row_format=dynamic page_encryption=1 page_encryption_key=2 page_compressed=1;
+create table innodb_dynamic(c1 bigint not null, b char(200)) engine=innodb row_format=dynamic page_encryption=1 page_encryption_key=2 page_compressed=1;
+show warnings;
+Level Code Message
+show create table innodb_normal;
+Table Create Table
+innodb_normal CREATE TABLE `innodb_normal` (
+ `c1` bigint(20) NOT NULL,
+ `b` char(200) DEFAULT NULL
+) ENGINE=InnoDB DEFAULT CHARSET=latin1 `page_compressed`=1
show create table innodb_compact;
Table Create Table
innodb_compact CREATE TABLE `innodb_compact` (
@@ -32,26 +40,71 @@ commit;
set autocommit=1;
insert into innodb_compact select * from innodb_normal;
insert into innodb_dynamic select * from innodb_normal;
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
+count(*)
+5000
select count(*) from innodb_compact where c1 < 1500000;
count(*)
5000
select count(*) from innodb_dynamic where c1 < 1500000;
count(*)
5000
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value >= 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value >= 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+variable_value >= 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+variable_value >= 0
+1
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
-set global innodb_compression_algorithm = 0;
+set global innodb_compression_algorithm = 1;
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
+count(*)
+5000
select count(*) from innodb_compact where c1 < 1500000;
count(*)
5000
select count(*) from innodb_dynamic where c1 < 1500000;
count(*)
5000
-alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT page_compressed=DEFAULT ;
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value >= 0
+1
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value >= 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
+SELECT variable_value > 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+variable_value > 0
+0
+SELECT variable_value > 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+variable_value > 0
+1
+alter table innodb_normal engine=innodb page_compressed=DEFAULT;
+show create table innodb_normal;
+Table Create Table
+innodb_normal CREATE TABLE `innodb_normal` (
+ `c1` bigint(20) NOT NULL,
+ `b` char(200) DEFAULT NULL
+) ENGINE=InnoDB DEFAULT CHARSET=latin1
+alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT page_compressed=DEFAULT;
show create table innodb_compact;
Table Create Table
innodb_compact CREATE TABLE `innodb_compact` (
@@ -67,6 +120,12 @@ innodb_dynamic CREATE TABLE `innodb_dynamic` (
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
+show create table innodb_normal;
+Table Create Table
+innodb_normal CREATE TABLE `innodb_normal` (
+ `c1` bigint(20) NOT NULL,
+ `b` char(200) DEFAULT NULL
+) ENGINE=InnoDB DEFAULT CHARSET=latin1
show create table innodb_compact;
Table Create Table
innodb_compact CREATE TABLE `innodb_compact` (
@@ -79,14 +138,33 @@ innodb_dynamic CREATE TABLE `innodb_dynamic` (
`c1` bigint(20) NOT NULL,
`b` char(200) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
+count(*)
+5000
select count(*) from innodb_compact where c1 < 1500000;
count(*)
5000
select count(*) from innodb_dynamic where c1 < 1500000;
count(*)
5000
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+variable_value = 0
+1
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+variable_value = 0
+1
drop procedure innodb_insert_proc;
drop table innodb_normal;
drop table innodb_compact;
diff --git a/mysql-test/suite/innodb/t/innodb-page_encryption.test b/mysql-test/suite/innodb/t/innodb-page_encryption.test
index 4159f82af62..f2866e35dca 100644
--- a/mysql-test/suite/innodb/t/innodb-page_encryption.test
+++ b/mysql-test/suite/innodb/t/innodb-page_encryption.test
@@ -51,6 +51,11 @@ select count(*) from innodb_compressed where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
select count(*) from innodb_redundant where c1 < 1500000;
+# Note there that these variables are updated only when real I/O is done, thus they are not reliable
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+
--source include/restart_mysqld.inc
SET GLOBAL innodb_file_format = `Barracuda`;
@@ -65,6 +70,10 @@ select count(*) from innodb_compressed where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
select count(*) from innodb_redundant where c1 < 1500000;
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+
alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT;
show create table innodb_compact;
alter table innodb_compressed engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT;
@@ -93,6 +102,11 @@ select count(*) from innodb_compressed where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
select count(*) from innodb_redundant where c1 < 1500000;
+# After alter+restart these should be 0
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+
drop procedure innodb_insert_proc;
drop table innodb_normal;
drop table innodb_compact;
diff --git a/mysql-test/suite/innodb/t/innodb-page_encryption_compression.test b/mysql-test/suite/innodb/t/innodb-page_encryption_compression.test
index 967654066c6..b32c92c613c 100644
--- a/mysql-test/suite/innodb/t/innodb-page_encryption_compression.test
+++ b/mysql-test/suite/innodb/t/innodb-page_encryption_compression.test
@@ -11,10 +11,12 @@ SET GLOBAL innodb_file_per_table = ON;
# zlib
set global innodb_compression_algorithm = 1;
-create table innodb_normal(c1 bigint not null, b char(200)) engine=innodb;
+create table innodb_normal(c1 bigint not null, b char(200)) engine=innodb page_compressed=1;
create table innodb_compact(c1 bigint not null, b char(200)) engine=innodb row_format=compact page_encryption=1 page_encryption_key=1 page_compressed=1;
-create table innodb_dynamic(c1 bigint not null, b char(200)) engine=innodb row_format=dynamic page_encryption=1 page_encryption_key=2 page_compressed=1;
+create table innodb_dynamic(c1 bigint not null, b char(200)) engine=innodb row_format=dynamic page_encryption=1 page_encryption_key=2 page_compressed=1;
+show warnings;
+show create table innodb_normal;
show create table innodb_compact;
show create table innodb_dynamic;
@@ -39,24 +41,42 @@ set autocommit=1;
insert into innodb_compact select * from innodb_normal;
insert into innodb_dynamic select * from innodb_normal;
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
select count(*) from innodb_compact where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+
--source include/restart_mysqld.inc
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
# zlib
-set global innodb_compression_algorithm = 0;
+set global innodb_compression_algorithm = 1;
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
select count(*) from innodb_compact where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
-alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT page_compressed=DEFAULT ;
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value >= 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+SELECT variable_value > 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+SELECT variable_value > 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+
+alter table innodb_normal engine=innodb page_compressed=DEFAULT;
+show create table innodb_normal;
+alter table innodb_compact engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT page_compressed=DEFAULT;
show create table innodb_compact;
alter table innodb_dynamic engine=innodb page_encryption=DEFAULT page_encryption_key=DEFAULT page_compressed=DEFAULT;
show create table innodb_dynamic;
@@ -66,14 +86,23 @@ show create table innodb_dynamic;
SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON;
+show create table innodb_normal;
show create table innodb_compact;
show create table innodb_dynamic;
+update innodb_normal set c1 = c1 + 1;
update innodb_compact set c1 = c1 + 1;
update innodb_dynamic set c1 = c1 + 1;
+select count(*) from innodb_normal;
select count(*) from innodb_compact where c1 < 1500000;
select count(*) from innodb_dynamic where c1 < 1500000;
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decrypted';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_encryption_error';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_compressed';
+SELECT variable_value = 0 FROM information_schema.global_status WHERE LOWER(variable_name) = 'innodb_num_pages_page_decompressed';
+
drop procedure innodb_insert_proc;
drop table innodb_normal;
drop table innodb_compact;
diff --git a/mysql-test/suite/sys_vars/r/innodb_data_encryption_filekey_basic.result b/mysql-test/suite/sys_vars/r/innodb_data_encryption_filekey_basic.result
new file mode 100644
index 00000000000..f7660620a2f
--- /dev/null
+++ b/mysql-test/suite/sys_vars/r/innodb_data_encryption_filekey_basic.result
@@ -0,0 +1,9 @@
+SELECT @start_data_encryption_filekey;
+@start_data_encryption_filekey
+NULL
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_filekey);
+COUNT(@@GLOBAL.innodb_data_encryption_filekey)
+0
+1 Expected
+SET @@GLOBAL.innodb_data_encryption_filekey='secret';
+ERROR HY000: Variable 'innodb_data_encryption_filekey' is a read only variable
diff --git a/mysql-test/suite/sys_vars/r/innodb_data_encryption_providername_basic.result b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providername_basic.result
new file mode 100644
index 00000000000..12b4407290b
--- /dev/null
+++ b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providername_basic.result
@@ -0,0 +1,9 @@
+SELECT @start_data_encryption_providername;
+@start_data_encryption_providername
+NULL
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providername);
+COUNT(@@GLOBAL.innodb_data_encryption_providername)
+0
+1 Expected
+SET @@GLOBAL.innodb_data_encryption_providername='key.txt';
+ERROR HY000: Variable 'innodb_data_encryption_providername' is a read only variable
diff --git a/mysql-test/suite/sys_vars/r/innodb_data_encryption_providertype_basic.result b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providertype_basic.result
new file mode 100644
index 00000000000..8a45857496e
--- /dev/null
+++ b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providertype_basic.result
@@ -0,0 +1,11 @@
+SELECT @start_data_encryption_providertype;
+@start_data_encryption_providertype
+NULL
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providertype);
+COUNT(@@GLOBAL.innodb_data_encryption_providertype)
+1
+1 Expected
+SET @@GLOBAL.innodb_data_encryption_providertype=1;
+ERROR HY000: Variable 'innodb_data_encryption_providertype' is a read only variable
+SET @@GLOBAL.innodb_data_encryption_providertype=k;
+ERROR HY000: Variable 'innodb_data_encryption_providertype' is a read only variable
diff --git a/mysql-test/suite/sys_vars/r/innodb_data_encryption_providerurl_basic.result b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providerurl_basic.result
new file mode 100644
index 00000000000..2a0fa74b347
--- /dev/null
+++ b/mysql-test/suite/sys_vars/r/innodb_data_encryption_providerurl_basic.result
@@ -0,0 +1,9 @@
+SELECT @start_data_encryption_providerurl;
+@start_data_encryption_providerurl
+NULL
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providerurl);
+COUNT(@@GLOBAL.innodb_data_encryption_providerurl)
+0
+1 Expected
+SET @@GLOBAL.innodb_data_encryption_providerurl='http://www.google.com';
+ERROR HY000: Variable 'innodb_data_encryption_providerurl' is a read only variable
diff --git a/mysql-test/suite/sys_vars/t/innodb_data_encryption_filekey_basic.test b/mysql-test/suite/sys_vars/t/innodb_data_encryption_filekey_basic.test
new file mode 100644
index 00000000000..569a948a2c7
--- /dev/null
+++ b/mysql-test/suite/sys_vars/t/innodb_data_encryption_filekey_basic.test
@@ -0,0 +1,13 @@
+--source include/have_xtradb.inc
+
+SELECT @start_data_encryption_filekey;
+
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_filekey);
+--echo 1 Expected
+
+# This variable is read only variable
+--error 1238
+SET @@GLOBAL.innodb_data_encryption_filekey='secret';
+
+
+
diff --git a/mysql-test/suite/sys_vars/t/innodb_data_encryption_providername_basic.test b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providername_basic.test
new file mode 100644
index 00000000000..688ceadc693
--- /dev/null
+++ b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providername_basic.test
@@ -0,0 +1,13 @@
+--source include/have_xtradb.inc
+
+SELECT @start_data_encryption_providername;
+
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providername);
+--echo 1 Expected
+
+# This variable is read only variable
+--error 1238
+SET @@GLOBAL.innodb_data_encryption_providername='key.txt';
+
+
+
diff --git a/mysql-test/suite/sys_vars/t/innodb_data_encryption_providertype_basic.test b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providertype_basic.test
new file mode 100644
index 00000000000..1d6c6249f05
--- /dev/null
+++ b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providertype_basic.test
@@ -0,0 +1,15 @@
+--source include/have_xtradb.inc
+
+SELECT @start_data_encryption_providertype;
+
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providertype);
+--echo 1 Expected
+
+# This variable is read only variable
+--error 1238
+SET @@GLOBAL.innodb_data_encryption_providertype=1;
+
+# This variable is read only variable
+--error 1238
+SET @@GLOBAL.innodb_data_encryption_providertype=k;
+
diff --git a/mysql-test/suite/sys_vars/t/innodb_data_encryption_providerurl_basic.test b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providerurl_basic.test
new file mode 100644
index 00000000000..c476b2180a9
--- /dev/null
+++ b/mysql-test/suite/sys_vars/t/innodb_data_encryption_providerurl_basic.test
@@ -0,0 +1,13 @@
+--source include/have_xtradb.inc
+
+SELECT @start_data_encryption_providerurl;
+
+SELECT COUNT(@@GLOBAL.innodb_data_encryption_providerurl);
+--echo 1 Expected
+
+# This variable is read only variable
+--error 1238
+SET @@GLOBAL.innodb_data_encryption_providerurl='http://www.google.com';
+
+
+