Skip to content

Commit 473fb92

Browse files
committed
MDEV-11454: Improve test case innodb_buffer_pool_dump_pct
Based off feedback from Marko Mäkelä: * Don't set timeouts on restart. * Use innodb_fast_shutdown=0 Also: Set innodb_buffer_pool_instances=1 - adds predicability to tests - if a biased pool is used less pages could be saved. Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
1 parent 84379b0 commit 473fb92

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

mysql-test/suite/sys_vars/r/innodb_buffer_pool_dump_pct_function.result

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
SET GLOBAL innodb_buffer_pool_dump_pct=25, global innodb_buffer_pool_dump_at_shutdown=1;;
21
# populate with data
32
CREATE TABLE t1 (
43
c01 blob, c02 blob, c03 blob, c04 blob, c05 blob,
@@ -31,6 +30,7 @@ INSERT INTO t1 VALUES (@a,@a,@a,@a,@a,
3130
@a,@a,@a,@a
3231
);
3332
insert into t1 select * from t1;
33+
SET GLOBAL innodb_buffer_pool_dump_pct=25,GLOBAL innodb_fast_shutdown=0, GLOBAL innodb_buffer_pool_dump_at_shutdown=1;
3434
# Restart server
3535
SET GLOBAL innodb_buffer_pool_load_now=1;
3636
# Case 1: Limit from innodb_buffer_pool_dump_pct

mysql-test/suite/sys_vars/t/innodb_buffer_pool_dump_pct_function.opt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
--loose-innodb_buffer_pool_load_at_startup=0
33
--loose-innodb_buffer_pool_dump_at_shutdown=0
44
--loose-innodb-buffer-pool-size=8M
5+
--loose-innodb-buffer-pool-instances=1
56
--loose-innodb-page-size=16k

mysql-test/suite/sys_vars/t/innodb_buffer_pool_dump_pct_function.test

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@
77

88
-- source include/have_innodb.inc
99

10-
--let $PCT=25
11-
12-
--eval SET GLOBAL innodb_buffer_pool_dump_pct=$PCT, global innodb_buffer_pool_dump_at_shutdown=1;
13-
1410
--echo # populate with data
1511

1612
CREATE TABLE t1 (
@@ -49,11 +45,12 @@ insert into t1 select * from t1;
4945

5046
--let $blob_pages=`select count(*) from information_schema.INNODB_BUFFER_PAGE WHERE PAGE_TYPE='BLOB' group by PAGE_TYPE`
5147

48+
--let $PCT=25
49+
--eval SET GLOBAL innodb_buffer_pool_dump_pct=$PCT,GLOBAL innodb_fast_shutdown=0, GLOBAL innodb_buffer_pool_dump_at_shutdown=1
50+
5251
# Dump on shutdown has been set - shutdown now
5352

5453
--echo # Restart server
55-
--let $shutdown_timeout= 10
56-
--let $allow_rpl_inited= 1
5754
--source include/restart_mysqld.inc
5855

5956
SET GLOBAL innodb_buffer_pool_load_now=1;

0 commit comments

Comments
 (0)