mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge kboortz@bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/Users/kent/mysql/bk/mysql-4.1
This commit is contained in:
@ -82,9 +82,16 @@ install-data-local:
|
||||
$(INSTALL_DATA) $(srcdir)/lib/init_db.sql $(DESTDIR)$(testdir)/lib
|
||||
$(INSTALL_DATA) $(srcdir)/lib/*.pl $(DESTDIR)$(testdir)/lib
|
||||
|
||||
std_data/%.pem:
|
||||
std_data/client-key.pem:
|
||||
@CP@ $(top_srcdir)/SSL/$(@F) $(srcdir)/std_data
|
||||
std_data/client-cert.pem:
|
||||
@CP@ $(top_srcdir)/SSL/$(@F) $(srcdir)/std_data
|
||||
std_data/cacert.pem:
|
||||
@CP@ $(top_srcdir)/SSL/$(@F) $(srcdir)/std_data
|
||||
std_data/server-cert.pem:
|
||||
@CP@ $(top_srcdir)/SSL/$(@F) $(srcdir)/std_data
|
||||
std_data/server-key.pem:
|
||||
@CP@ $(top_srcdir)/SSL/$(@F) $(srcdir)/std_data
|
||||
|
||||
|
||||
SUFFIXES = .sh
|
||||
|
||||
|
@ -4,6 +4,12 @@
|
||||
# the $variables is extreme sensitive.
|
||||
#
|
||||
|
||||
###############################################################
|
||||
# Debug options : To debug this test script
|
||||
###############################################################
|
||||
let $showbinlog= 0;
|
||||
let $manipulate= 1;
|
||||
|
||||
######## The typical test sequence
|
||||
# 1. INSERT without commit
|
||||
# check table content of master and slave
|
||||
@ -52,9 +58,12 @@ let $MAX= `SELECT MAX(f1) FROM t1` ;
|
||||
eval INSERT INTO t1 SET f1= $MAX + 1;
|
||||
# results before DDL(to be tested)
|
||||
SELECT MAX(f1) FROM t1;
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'master-bin.$_log_num_s';
|
||||
}
|
||||
sync_slave_with_master;
|
||||
|
||||
connection slave;
|
||||
@ -63,9 +72,12 @@ SELECT '-------- switch to slave --------' as "";
|
||||
--enable_query_log
|
||||
# results before DDL(to be tested)
|
||||
SELECT MAX(f1) FROM t1;
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'slave-bin.$_log_num_s';
|
||||
}
|
||||
|
||||
###############################################################
|
||||
# command to be tested
|
||||
@ -79,9 +91,12 @@ eval $my_stmt;
|
||||
let $my_stmt= ERROR: YOU FORGOT TO FILL IN THE STATEMENT;
|
||||
# results after DDL(to be tested)
|
||||
SELECT MAX(f1) FROM t1;
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'master-bin.$_log_num_s';
|
||||
}
|
||||
sync_slave_with_master;
|
||||
|
||||
connection slave;
|
||||
@ -90,9 +105,12 @@ SELECT '-------- switch to slave --------' as "";
|
||||
--enable_query_log
|
||||
# results after DDL(to be tested)
|
||||
SELECT MAX(f1) FROM t1;
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'slave-bin.$_log_num_s';
|
||||
}
|
||||
|
||||
###############################################################
|
||||
# ROLLBACK
|
||||
@ -114,9 +132,12 @@ eval SELECT CONCAT(CONCAT('TEST-INFO: MASTER: The INSERT is ',
|
||||
' (Failed)')) AS ""
|
||||
FROM mysqltest1.t1;
|
||||
--enable_query_log
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'master-bin.$_log_num_s';
|
||||
}
|
||||
sync_slave_with_master;
|
||||
|
||||
connection slave;
|
||||
@ -133,16 +154,17 @@ eval SELECT CONCAT(CONCAT('TEST-INFO: SLAVE: The INSERT is ',
|
||||
' (Failed)')) AS ""
|
||||
FROM mysqltest1.t1;
|
||||
--enable_query_log
|
||||
if ($show_binlog)
|
||||
{
|
||||
--replace_result $VERSION VERSION
|
||||
--replace_column 2 # 5 #
|
||||
eval SHOW BINLOG EVENTS IN 'slave-bin.$_log_num_s';
|
||||
}
|
||||
|
||||
###############################################################
|
||||
# Manipulate binlog
|
||||
###############################################################
|
||||
#let $manipulate= 0;
|
||||
let $manipulate= 1;
|
||||
while ($manipulate)
|
||||
if ($manipulate)
|
||||
{
|
||||
#### Manipulate the binary logs,
|
||||
# so that the output of SHOW BINLOG EVENTS IN <current log>
|
||||
@ -171,7 +193,6 @@ flush logs;
|
||||
# sleep 1;
|
||||
# eval SHOW BINLOG EVENTS IN 'slave-bin.$_log_num_s';
|
||||
inc $_log_num_n;
|
||||
let $manipulate= 0;
|
||||
}
|
||||
|
||||
connection master;
|
||||
|
@ -12,10 +12,9 @@ show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
drop table t1;
|
||||
commit;
|
||||
set autocommit=1;
|
||||
begin;
|
||||
create table t1 (a int not null) engine=bdb;
|
||||
begin;
|
||||
insert into t1 values (1),(2),(3);
|
||||
select * from t1;
|
||||
a
|
||||
@ -26,7 +25,6 @@ show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
drop table t1;
|
||||
commit;
|
||||
create table t1 (a int not null) engine=bdb;
|
||||
create table t2 (a int not null) engine=bdb;
|
||||
create table t3 (a int not null) engine=bdb;
|
||||
|
@ -78,4 +78,4 @@ drop database mysqltest;
|
||||
prepare stmt4 from ' show full processlist ';
|
||||
execute stmt4;
|
||||
Id User Host db Command Time State Info
|
||||
number root localhost test Query time NULL show full processlist
|
||||
number root localhost test Execute time NULL show full processlist
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -14,15 +14,13 @@ insert into t1 values (1),(2),(3);
|
||||
select * from t1;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
drop table t1;
|
||||
commit;
|
||||
set autocommit=1;
|
||||
begin;
|
||||
create table t1 (a int not null) engine=bdb;
|
||||
begin;
|
||||
insert into t1 values (1),(2),(3);
|
||||
select * from t1;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
drop table t1;
|
||||
commit;
|
||||
create table t1 (a int not null) engine=bdb;
|
||||
create table t2 (a int not null) engine=bdb;
|
||||
create table t3 (a int not null) engine=bdb;
|
||||
|
@ -253,6 +253,8 @@ let $my_slave_commit= false;
|
||||
--source include/rpl_stmt_seq.inc
|
||||
|
||||
# With prior read locking
|
||||
# Note that this test generate an error since the rpl_stmt_seq.inc
|
||||
# tries to insert into t1.
|
||||
LOCK TABLES mysqltest1.t1 READ;
|
||||
let $my_stmt= UNLOCK TABLES;
|
||||
let $my_master_commit= false;
|
||||
|
Reference in New Issue
Block a user