mirror of
https://github.com/MariaDB/server.git
synced 2025-01-18 04:53:01 +01:00
2855415058
+ fix for #70 + test result fix for LOAD DATA LOCAL bug #82 client/mysqltest.c: Removed wrong comment and useless sleep mysql-test/mysql-test-run.sh: Fix $slave_datadir variable because this if [ -n "$1" ] ; slave_datadir="var/$slave_ident-data/" else slave_datadir=$SLAVE_MYDDIR was not coherent and led to problems of master.info not being deleted. Delete relay-log.info too. mysql-test/r/rpl000001.result: SUM is 1022 (1021 was when we had the LOAD DATA LOCAL bug #82). It's logical to have an even number as we load the same file twice. sql/slave.cc: When we RESET SLAVE, clear rli->master_log_* to give a good display in SHOW SLAVE STATUS ; seeing the old values may confuse the user. When we START SLAVE, clear rli->master_log_name, not only rli->master_log_pos. sql/sql_repl.cc: When we RESET SLAVE, clear mi->master_log_* to give a good display in SHOW SLAVE STATUS (bug #70)
83 lines
1.9 KiB
Text
83 lines
1.9 KiB
Text
slave stop;
|
|
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
|
reset master;
|
|
reset slave;
|
|
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
|
slave start;
|
|
drop table if exists t1,t2,t3;
|
|
create table t1 (word char(20) not null);
|
|
load data infile '../../std_data/words.dat' into table t1;
|
|
load data local infile 'MYSQL_TEST_DIR/std_data/words.dat' into table t1;
|
|
select * from t1 limit 10;
|
|
word
|
|
Aarhus
|
|
Aaron
|
|
Ababa
|
|
aback
|
|
abaft
|
|
abandon
|
|
abandoned
|
|
abandoning
|
|
abandonment
|
|
abandons
|
|
slave stop;
|
|
set password for root@"localhost" = password('foo');
|
|
slave start;
|
|
set password for root@"localhost" = password('');
|
|
create table t3(n int);
|
|
insert into t3 values(1),(2);
|
|
select * from t3;
|
|
n
|
|
1
|
|
2
|
|
select sum(length(word)) from t1;
|
|
sum(length(word))
|
|
1022
|
|
drop table t1,t3;
|
|
reset master;
|
|
slave stop;
|
|
reset slave;
|
|
create table t1(n int);
|
|
select get_lock("hold_slave",10);
|
|
get_lock("hold_slave",10)
|
|
1
|
|
slave start;
|
|
select release_lock("hold_slave");
|
|
release_lock("hold_slave")
|
|
1
|
|
unlock tables;
|
|
create table t2(id int);
|
|
insert into t2 values(connection_id());
|
|
create temporary table t3(n int);
|
|
insert into t3 select get_lock('crash_lock%20C', 1) from t2;
|
|
update t1 set n = n + get_lock('crash_lock%20C', 2);
|
|
select (@id := id) - id from t2;
|
|
(@id := id) - id
|
|
0
|
|
kill @id;
|
|
drop table t2;
|
|
Server shutdown in progress
|
|
set global sql_slave_skip_counter=1;
|
|
slave start;
|
|
select count(*) from t1;
|
|
count(*)
|
|
5000
|
|
drop table t1;
|
|
create table t1 (n int);
|
|
insert into t1 values(3456);
|
|
insert into mysql.user (Host, User, Password)
|
|
VALUES ("10.10.10.%", "blafasel2", password("blafasel2"));
|
|
select select_priv,user from mysql.user where user = 'blafasel2';
|
|
select_priv user
|
|
N blafasel2
|
|
update mysql.user set Select_priv = "Y" where User="blafasel2";
|
|
select select_priv,user from mysql.user where user = 'blafasel2';
|
|
select_priv user
|
|
Y blafasel2
|
|
select n from t1;
|
|
n
|
|
3456
|
|
select select_priv,user from mysql.user where user = 'blafasel2';
|
|
select_priv user
|
|
Y blafasel2
|
|
drop table t1;
|