summaryrefslogtreecommitdiff
path: root/mysql-test/suite/innodb/r/innodb-page_compression_zip.result
blob: d98b4e8e229387f3ac21de48cc82fbf420365bd7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
set global innodb_compression_algorithm = zlib;
select @@innodb_compression_algorithm;
@@innodb_compression_algorithm
zlib
set global innodb_file_format = `Barracuda`;
set global innodb_file_per_table = on;
call mtr.add_suppression("InnoDB: Database page corruption on disk or a failed file read of tablespace test/t[0-9]+ page \\[page id: space=[0-9]+, page number=[0-9]+\\]. You may have to recover from a backup.");
call mtr.add_suppression("InnoDB: Page \\[page id: space=[0-9]+, page number= [0-9]+\\] in file ./test/t[0-9]+.ibd may be corrupted. Post compression checksum [0-9]+ stored [0-9]+ compression_method [ZLIB|SNAPPY|LZ4|LZO|LZMA|BZIP2]");
call mtr.add_suppression("InnoDB: Background Page read failed to read or decrypt \\[page id: space=[0-9]+, page number=[0-9]+\\]");
call mtr.add_suppression("mysqld: Index for table 't[0-9]+' is corrupt; try to repair it");
create table t0 (c1 int not null auto_increment primary key, b char(200)) engine=innodb;
create table t1 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=1;
create table t2 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=2;
create table t3 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=3;
create table t4 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=4;
create table t5 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=5;
create table t6 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=6;
create table t7 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=7;
create table t8 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=8;
create table t9 (c1 int not null auto_increment primary key, b char(200)) engine=innodb page_compressed=1 page_compression_level=9;
select count(*) from t1;
count(*)
500
select count(*) from t3;
count(*)
500
select count(*) from t4;
count(*)
500
select count(*) from t5;
count(*)
500
select count(*) from t6;
count(*)
500
select count(*) from t6;
count(*)
500
select count(*) from t7;
count(*)
500
select count(*) from t8;
count(*)
500
select count(*) from t9;
count(*)
500
# t0 expected FOUND
FOUND /AaAaAaAa/ in t0.ibd
# t1 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t1.ibd
# t2 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t2.ibd
# t3 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t3.ibd
# t4 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t4.ibd
# t5 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t5.ibd
# t6 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t6.ibd
# t7 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t7.ibd
# t8 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t8.ibd
# t9 page compressed expected NOT FOUND
NOT FOUND /AaAaAaAa/ in t9.ibd
# Run innochecksum on t9
# Run innochecksum on t8
# Run innochecksum on t7
# Run innochecksum on t6
# Run innochecksum on t5
# Run innochecksum on t4
# Run innochecksum on t3
# Run innochecksum on t2
# Run innochecksum on t1
select count(*) from t0;
count(*)
500
select count(*) from t1;
count(*)
500
select count(*) from t3;
count(*)
500
select count(*) from t4;
count(*)
500
select count(*) from t5;
count(*)
500
select count(*) from t6;
count(*)
500
select count(*) from t7;
count(*)
500
select count(*) from t8;
count(*)
500
select count(*) from t9;
count(*)
500
# Restart server
# Corrupting tablespaces...
# Corruption done
# Run innochecksum on t4
# Run innochecksum on t3
# Run innochecksum on t2
# Run innochecksum on t1
# Start server again
select * from t1;
ERROR HY000: Incorrect key file for table 't1'; try to repair it
select * from t2;
ERROR HY000: Incorrect key file for table 't2'; try to repair it
select * from t3;
ERROR HY000: Incorrect key file for table 't3'; try to repair it
select * from t4;
ERROR HY000: Incorrect key file for table 't4'; try to repair it
select count(*) from t5;
count(*)
500
select count(*) from t6;
count(*)
500
select count(*) from t7;
count(*)
500
select count(*) from t8;
count(*)
500
select count(*) from t9;
count(*)
500
drop table t0, t1, t2, t3, t4, t5, t6, t7, t8, t9;