Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
b75d8453
Commit
b75d8453
authored
Feb 07, 2018
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-14868 MariaDB server crashes after using ROLLBACK TO when encrypt_tmp_files=ON
add a test that restores the data from a binlog
parent
60dfe12b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
76 additions
and
12 deletions
+76
-12
mysql-test/suite/encryption/r/tempfiles.result
mysql-test/suite/encryption/r/tempfiles.result
+60
-6
mysql-test/suite/encryption/t/tempfiles.test
mysql-test/suite/encryption/t/tempfiles.test
+16
-6
No files found.
mysql-test/suite/encryption/r/tempfiles.result
View file @
b75d8453
...
...
@@ -28,6 +28,7 @@ h 10
i 10
j 10
drop table t1;
reset master;
set global binlog_cache_size=8192;
create table t1 (a text) engine=innodb;
start transaction;
...
...
@@ -36,14 +37,67 @@ commit;
start transaction;
insert t1 select repeat(seq, 1000) from seq_1_to_8;
commit;
drop table t1;
create table t1 (a text) engine=innodb;
create table t2 (a text) engine=innodb;
start transaction;
insert t
1
select repeat(seq, 1000) from seq_1_to_15;
insert t
2
select repeat(seq, 1000) from seq_1_to_15;
savepoint foo;
insert t
1
select repeat(seq, 1000) from seq_16_to_30;
insert t
2
select repeat(seq, 1000) from seq_16_to_30;
rollback to savepoint foo;
insert t
1
select repeat(seq, 1000) from seq_31_to_40;
insert t
2
select repeat(seq, 1000) from seq_31_to_40;
commit;
drop table t1;
flush binary logs;
drop table t1, t2;
set global binlog_cache_size=default;
select left(a, 10) from t1;
left(a, 10)
1111111111
2222222222
3333333333
4444444444
5555555555
6666666666
7777777777
8888888888
9999999999
1010101010
1111111111
1212121212
1313131313
1414141414
1515151515
1111111111
2222222222
3333333333
4444444444
5555555555
6666666666
7777777777
8888888888
select left(a, 10) from t2;
left(a, 10)
1111111111
2222222222
3333333333
4444444444
5555555555
6666666666
7777777777
8888888888
9999999999
1010101010
1111111111
1212121212
1313131313
1414141414
1515151515
3131313131
3232323232
3333333333
3434343434
3535353535
3636363636
3737373737
3838383838
3939393939
4040404040
drop table t1, t2;
mysql-test/suite/encryption/t/tempfiles.test
View file @
b75d8453
...
...
@@ -33,6 +33,7 @@ update t1 set c=v, t=v;
select
sql_big_result
t
,
count
(
t
)
from
t1
group
by
t
limit
10
;
drop
table
t1
;
reset
master
;
set
global
binlog_cache_size
=
8192
;
connect
con1
,
localhost
,
root
;
...
...
@@ -50,7 +51,6 @@ commit;
start
transaction
;
insert
t1
select
repeat
(
seq
,
1000
)
from
seq_1_to_8
;
commit
;
drop
table
t1
;
disconnect
con1
;
connect
con2
,
localhost
,
root
;
...
...
@@ -60,17 +60,27 @@ connect con2, localhost, root;
# Start a transaction, write until the cache goes to disk,
# create a savepoint, write more blocks to disk, rollback to savepoint.
#
create
table
t
1
(
a
text
)
engine
=
innodb
;
create
table
t
2
(
a
text
)
engine
=
innodb
;
start
transaction
;
insert
t
1
select
repeat
(
seq
,
1000
)
from
seq_1_to_15
;
insert
t
2
select
repeat
(
seq
,
1000
)
from
seq_1_to_15
;
savepoint
foo
;
insert
t
1
select
repeat
(
seq
,
1000
)
from
seq_16_to_30
;
insert
t
2
select
repeat
(
seq
,
1000
)
from
seq_16_to_30
;
rollback
to
savepoint
foo
;
insert
t
1
select
repeat
(
seq
,
1000
)
from
seq_31_to_40
;
insert
t
2
select
repeat
(
seq
,
1000
)
from
seq_31_to_40
;
commit
;
drop
table
t1
;
disconnect
con2
;
connection
default
;
flush
binary
logs
;
drop
table
t1
,
t2
;
set
global
binlog_cache_size
=
default
;
let
$MYSQLD_DATADIR
=
`select @@datadir`
;
exec
$MYSQL_BINLOG
$MYSQLD_DATADIR
/
master
-
bin
.
000001
|
$MYSQL
;
select
left
(
a
,
10
)
from
t1
;
select
left
(
a
,
10
)
from
t2
;
drop
table
t1
,
t2
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment