diff options
author | unknown <serg@serg.mylan> | 2005-02-20 15:53:40 +0100 |
---|---|---|
committer | unknown <serg@serg.mylan> | 2005-02-20 15:53:40 +0100 |
commit | e694e9654238e335626dcd4fc90692ce0dd82a2f (patch) | |
tree | ebe319bfa6371ac2ca52d2e2450338b9bcbd2f4d /mysql-test/t | |
parent | da4604f9e8fa42c8e7c5627b692e0ac6d5409802 (diff) | |
parent | 915660e03d5eb718595b77c11cd8d21f8557867d (diff) | |
download | mariadb-git-e694e9654238e335626dcd4fc90692ce0dd82a2f.tar.gz |
Merge bk-internal:/home/bk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/rpl_trunc_binlog.test | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/mysql-test/t/rpl_trunc_binlog.test b/mysql-test/t/rpl_trunc_binlog.test index b2e7e52f5e4..eec36532275 100644 --- a/mysql-test/t/rpl_trunc_binlog.test +++ b/mysql-test/t/rpl_trunc_binlog.test @@ -1,21 +1,28 @@ # We are testing if a binlog which contains BEGIN but not COMMIT (the -# master did while writing the transaction to the binlog) triggers an -# error on slave. So we use such a truncated binlog and simulate that +# master died while writing the transaction to the binlog) triggers a +# rollback on slave. So we use such a truncated binlog and simulate that # the master restarted after this. source include/master-slave.inc; connection slave; -# If we are not supporting transactions in the slave, the unfinished transaction -# won't cause any error, so we need to skip the test. In the 4.0 testsuite, the -# slave always runs without InnoDB, so we check for BDB. +# If we are not supporting transactions in the slave, the unfinished +# transaction won't cause any error, so we need to skip the test. In the 4.0 +# testsuite, the slave always runs without InnoDB, so we check for BDB. source include/have_bdb.inc; stop slave; + connection master; flush logs; system mv -f var/log/master-bin.000001 var/log/master-bin.000002; system cp std_data/trunc_binlog.000001 var/log/master-bin.000001; + connection slave; + +# truncated binlog contains: BEGIN; INSERT t1 VALUES (1); +# so let's create the table t1 on slave + +create table t1 (a int) engine=bdb; reset slave; start slave; # can't sync_with_master so we must sleep @@ -23,3 +30,6 @@ sleep 3; --replace_result $MASTER_MYPORT MASTER_PORT --replace_column 1 # 8 # 9 # 23 # 33 # show slave status; +select * from t1; +drop table t1; + |