summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <sasha@mysql.sashanet.com>2002-03-15 18:44:44 -0700
committerunknown <sasha@mysql.sashanet.com>2002-03-15 18:44:44 -0700
commit9c435716a9773f78cd5db0a992bd4b89b83bc25a (patch)
treefd01da1dc4d0055ee7386fa88268c65589a33c64 /mysql-test
parentb8a9ea66ba2663d10e2ef2ed138fa1576b15320e (diff)
downloadmariadb-git-9c435716a9773f78cd5db0a992bd4b89b83bc25a.tar.gz
replication updates and bugfixes. Still not perfect - there is some strange
memory corruption I can only repeat on one system. mysql-test/r/multi_update.result: extended test trying to find why the old one was failing mysql-test/r/rpl000015.result: result update mysql-test/t/multi_update.test: updated test to do more intermediate result checks mysql-test/t/rpl000014.test: cosmetic change mysql-test/t/rpl000015-slave-master-info.opt: reduce connect retry trying to simulate a bug mysql-test/t/rpl000015.test: cosmetic change sql/lex.h: added RELAY_LOG_FILE and RELAY_LOG_POS to CHANGE MASTER TO sql/log.cc: fixed replication bug sql/log_event.cc: properly ignore replication errors according to error mask sql/mysqld.cc: handle SIGFPE in the coredump handler sql/slave.cc: do not kick slave if it has already exited and freed the structures sql/sql_lex.cc: fixed initialization bug in CHANGE MASTER TO sql/sql_lex.h: CHANGE MASTER TO .. RELAY_LOG_FILE=,RELAY_LOG_POS= sql/sql_repl.cc: CHANGE MASTER TO .. RELAY_LOG_FILE=,RELAY_LOG_POS= sql/sql_yacc.yy: CHANGE MASTER TO .. RELAY_LOG_FILE=,RELAY_LOG_POS=
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/multi_update.result27
-rw-r--r--mysql-test/r/rpl000015.result6
-rw-r--r--mysql-test/t/multi_update.test11
-rw-r--r--mysql-test/t/rpl000014.test1
-rw-r--r--mysql-test/t/rpl000015-slave-master-info.opt2
-rw-r--r--mysql-test/t/rpl000015.test1
6 files changed, 44 insertions, 4 deletions
diff --git a/mysql-test/r/multi_update.result b/mysql-test/r/multi_update.result
index b1423667c44..85819d9571d 100644
--- a/mysql-test/r/multi_update.result
+++ b/mysql-test/r/multi_update.result
@@ -2,7 +2,34 @@ drop table if exists t1,t2,t3;
create table t1(id1 int not null auto_increment primary key, t char(12));
create table t2(id2 int not null, t char(12));
create table t3(id3 int not null, t char(12), index(id3));
+select count(*) from t1 where id1 > 95;
+count(*)
+5
+select count(*) from t2 where id2 > 95;
+count(*)
+25
+select count(*) from t3 where id3 > 95;
+count(*)
+250
update t1,t2,t3 set t1.t="aaa", t2.t="bbb", t3.t="cc" where t1.id1 = t2.id2 and t2.id2 = t3.id3 and t1.id1 > 90;
+select count(*) from t1 where t = "aaa";
+count(*)
+10
+select count(*) from t1 where id1 > 90;
+count(*)
+10
+select count(*) from t2 where t = "bbb";
+count(*)
+10
+select count(*) from t2 where id2 > 90;
+count(*)
+50
+select count(*) from t3 where t = "cc";
+count(*)
+500
+select count(*) from t3 where id3 > 90;
+count(*)
+500
delete t1.*, t2.*, t3.* from t1,t2,t3 where t1.id1 = t2.id2 and t2.id2 = t3.id3 and t1.id1 > 95;
check table t1, t2, t3;
Table Op Msg_type Msg_text
diff --git a/mysql-test/r/rpl000015.result b/mysql-test/r/rpl000015.result
index 03370bc6b0d..1546e5eb48d 100644
--- a/mysql-test/r/rpl000015.result
+++ b/mysql-test/r/rpl000015.result
@@ -9,16 +9,16 @@ Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Lo
change master to master_host='127.0.0.1';
show slave status;
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos
-127.0.0.1 test MASTER_PORT 60 4 slave-relay-bin.001 4 No No 0 0 0
+127.0.0.1 test MASTER_PORT 7 4 slave-relay-bin.001 4 No No 0 0 0
change master to master_host='127.0.0.1',master_user='root',
master_password='',master_port=MASTER_PORT;
show slave status;
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos
-127.0.0.1 root MASTER_PORT 60 4 slave-relay-bin.001 4 No No 0 0 0
+127.0.0.1 root MASTER_PORT 7 4 slave-relay-bin.001 4 No No 0 0 0
slave start;
show slave status;
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos
-127.0.0.1 root MASTER_PORT 60 master-bin.001 79 slave-relay-bin.001 120 master-bin.001 Yes Yes 0 0 79
+127.0.0.1 root MASTER_PORT 7 master-bin.001 79 slave-relay-bin.001 120 master-bin.001 Yes Yes 0 0 79
drop table if exists t1;
create table t1 (n int);
insert into t1 values (10),(45),(90);
diff --git a/mysql-test/t/multi_update.test b/mysql-test/t/multi_update.test
index 11697f794a9..c16189168d2 100644
--- a/mysql-test/t/multi_update.test
+++ b/mysql-test/t/multi_update.test
@@ -29,7 +29,18 @@ while ($1)
dec $1;
}
enable_query_log;
+
+select count(*) from t1 where id1 > 95;
+select count(*) from t2 where id2 > 95;
+select count(*) from t3 where id3 > 95;
+
update t1,t2,t3 set t1.t="aaa", t2.t="bbb", t3.t="cc" where t1.id1 = t2.id2 and t2.id2 = t3.id3 and t1.id1 > 90;
+select count(*) from t1 where t = "aaa";
+select count(*) from t1 where id1 > 90;
+select count(*) from t2 where t = "bbb";
+select count(*) from t2 where id2 > 90;
+select count(*) from t3 where t = "cc";
+select count(*) from t3 where id3 > 90;
delete t1.*, t2.*, t3.* from t1,t2,t3 where t1.id1 = t2.id2 and t2.id2 = t3.id3 and t1.id1 > 95;
check table t1, t2, t3;
diff --git a/mysql-test/t/rpl000014.test b/mysql-test/t/rpl000014.test
index a673a23dde2..df15fa6e600 100644
--- a/mysql-test/t/rpl000014.test
+++ b/mysql-test/t/rpl000014.test
@@ -8,6 +8,7 @@ sync_with_master;
show slave status;
change master to master_log_pos=73;
slave stop;
+
change master to master_log_pos=73;
--replace_result 3306 MASTER_PORT 9306 MASTER_PORT 3334 MASTER_PORT 3336 MASTER_PORT
show slave status;
diff --git a/mysql-test/t/rpl000015-slave-master-info.opt b/mysql-test/t/rpl000015-slave-master-info.opt
index 80190bf6d29..28bc753dd56 100644
--- a/mysql-test/t/rpl000015-slave-master-info.opt
+++ b/mysql-test/t/rpl000015-slave-master-info.opt
@@ -1 +1 @@
---server-id=2
+--server-id=22 --master-connect-retry=7
diff --git a/mysql-test/t/rpl000015.test b/mysql-test/t/rpl000015.test
index 8fd04613ab8..c42e14699c5 100644
--- a/mysql-test/t/rpl000015.test
+++ b/mysql-test/t/rpl000015.test
@@ -8,6 +8,7 @@ connection slave;
reset slave;
--replace_result $MASTER_MYPORT MASTER_PORT
show slave status;
+
change master to master_host='127.0.0.1';
# The following needs to be cleaned up when change master is fixed
--replace_result $MASTER_MYPORT MASTER_PORT 3306 MASTER_PORT 3334 MASTER_PORT