summaryrefslogtreecommitdiff
path: root/mysql-test/t/rpl_many_optimize.test
blob: 525e23abe151bf8548db3238335f948b1de7cc6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# Test for BUG#7658 "optimize crashes slave thread (1 in 1000)]"

source include/master-slave.inc;

create table t1 (a int not null auto_increment primary key, b int, key(b));
INSERT INTO t1 (a) VALUES (1),(2);
# Now many OPTIMIZE to test if we crash (BUG#7658)
let $1=300;
disable_query_log;
disable_result_log;
while ($1)
{
 eval OPTIMIZE TABLE t1;
 dec $1;
}
enable_result_log;
enable_query_log;
drop table t1;
# Bug was that slave segfaulted after ~ a hundred of OPTIMIZE (or ANALYZE)
sync_slave_with_master;