diff options
author | Michael Widenius <monty@askmonty.org> | 2011-05-10 18:17:43 +0300 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2011-05-10 18:17:43 +0300 |
commit | ce3b7273a6b5b5bf3dc4a0f3c72ef9889d091f59 (patch) | |
tree | d7eed818fd8b648e5eabe0dbad53e61665d8dc37 /mysql-test/suite/binlog | |
parent | 355e250544e69df7b547d8950bc9febfc5668be6 (diff) | |
parent | 82b49178600e3b21f378bef71b8f9e81bc7bcd3a (diff) | |
download | mariadb-git-ce3b7273a6b5b5bf3dc4a0f3c72ef9889d091f59.tar.gz |
Merge with MariaDB 5.2
Diffstat (limited to 'mysql-test/suite/binlog')
-rw-r--r-- | mysql-test/suite/binlog/r/binlog_base64_flag.result | 2 | ||||
-rw-r--r-- | mysql-test/suite/binlog/r/binlog_bug23533.result | 15 | ||||
-rw-r--r-- | mysql-test/suite/binlog/r/binlog_bug36391.result | 10 | ||||
-rw-r--r-- | mysql-test/suite/binlog/r/binlog_row_binlog.result | 1 | ||||
-rw-r--r-- | mysql-test/suite/binlog/r/binlog_stm_binlog.result | 1 | ||||
-rw-r--r-- | mysql-test/suite/binlog/t/binlog_base64_flag.test | 2 | ||||
-rw-r--r-- | mysql-test/suite/binlog/t/binlog_bug23533.test | 50 | ||||
-rw-r--r-- | mysql-test/suite/binlog/t/binlog_bug36391-master.opt | 1 | ||||
-rw-r--r-- | mysql-test/suite/binlog/t/binlog_bug36391.test | 30 | ||||
-rw-r--r-- | mysql-test/suite/binlog/t/binlog_index.test | 2 |
10 files changed, 114 insertions, 0 deletions
diff --git a/mysql-test/suite/binlog/r/binlog_base64_flag.result b/mysql-test/suite/binlog/r/binlog_base64_flag.result index 7fb5e50a219..a4c610c845a 100644 --- a/mysql-test/suite/binlog/r/binlog_base64_flag.result +++ b/mysql-test/suite/binlog/r/binlog_base64_flag.result @@ -91,6 +91,8 @@ iONkSBcBAAAAKwAAAMQBAAAQABAAAAAAAAEAA//4AQAAAAMAMTIzAQAAAA== '; ERROR HY000: master may suffer from http://bugs.mysql.com/bug.php?id=37426 so slave stops; check error log on slave for more info drop table t1, char63_utf8, char128_utf8; +call mtr.add_suppression("Slave SQL.*master suffers from this bug: http:..bugs.mysql.com.bug.php.id=37426.* Error_code: 1105"); +call mtr.add_suppression("Slave SQL.*Table definition on master and slave does not match: Column 1 size mismatch.* Error_code: 1535"); # # Bug #54393: crash and/or valgrind errors in # mysql_client_binlog_statement diff --git a/mysql-test/suite/binlog/r/binlog_bug23533.result b/mysql-test/suite/binlog/r/binlog_bug23533.result new file mode 100644 index 00000000000..d5cd93284a2 --- /dev/null +++ b/mysql-test/suite/binlog/r/binlog_bug23533.result @@ -0,0 +1,15 @@ +SET AUTOCOMMIT=0; +CREATE TABLE t1 (a INT NOT NULL AUTO_INCREMENT, b TEXT, PRIMARY KEY(a)) ENGINE=InnoDB; +SELECT COUNT(*) FROM t1; +COUNT(*) +1000 +SET GLOBAL binlog_cache_size=4096; +SET GLOBAL max_binlog_cache_size=4096; +START TRANSACTION; +CREATE TABLE t2 SELECT * FROM t1; +ERROR HY000: Multi-statement transaction required more than 'max_binlog_cache_size' bytes of storage; increase this mysqld variable and try again +COMMIT; +SHOW TABLES LIKE 't%'; +Tables_in_test (t%) +t1 +DROP TABLE t1; diff --git a/mysql-test/suite/binlog/r/binlog_bug36391.result b/mysql-test/suite/binlog/r/binlog_bug36391.result new file mode 100644 index 00000000000..551bfb9924d --- /dev/null +++ b/mysql-test/suite/binlog/r/binlog_bug36391.result @@ -0,0 +1,10 @@ +CREATE TABLE t1(id INT); +SHOW TABLES; +Tables_in_test +t1 +FLUSH LOGS; +DROP TABLE t1; +SHOW TABLES; +Tables_in_test +t1 +DROP TABLE t1; diff --git a/mysql-test/suite/binlog/r/binlog_row_binlog.result b/mysql-test/suite/binlog/r/binlog_row_binlog.result index 5401e6de24e..a30dc69c7c0 100644 --- a/mysql-test/suite/binlog/r/binlog_row_binlog.result +++ b/mysql-test/suite/binlog/r/binlog_row_binlog.result @@ -782,6 +782,7 @@ unique_checks OFF # INSERT INTO t1 VALUES(2) # foreign_key_checks=1 and unique_checks=1 # It should not change current session's variables, even error happens +call mtr.add_suppression("Slave SQL.*Could not execute Write_rows event on table test.t1; Duplicate entry .2. for key .PRIMARY., Error_code: 1062"); BINLOG ' dfLtTBMBAAAAKQAAAKsBAAAAABcAAAAAAAEABHRlc3QAAnQxAAEDAAE= dfLtTBcBAAAAIgAAAM0BAAAAABcAAAAAAAEAAf/+AgAAAA== diff --git a/mysql-test/suite/binlog/r/binlog_stm_binlog.result b/mysql-test/suite/binlog/r/binlog_stm_binlog.result index 020f2d068fb..5b324150d5a 100644 --- a/mysql-test/suite/binlog/r/binlog_stm_binlog.result +++ b/mysql-test/suite/binlog/r/binlog_stm_binlog.result @@ -555,6 +555,7 @@ unique_checks OFF # INSERT INTO t1 VALUES(2) # foreign_key_checks=1 and unique_checks=1 # It should not change current session's variables, even error happens +call mtr.add_suppression("Slave SQL.*Could not execute Write_rows event on table test.t1; Duplicate entry .2. for key .PRIMARY., Error_code: 1062"); BINLOG ' dfLtTBMBAAAAKQAAAKsBAAAAABcAAAAAAAEABHRlc3QAAnQxAAEDAAE= dfLtTBcBAAAAIgAAAM0BAAAAABcAAAAAAAEAAf/+AgAAAA== diff --git a/mysql-test/suite/binlog/t/binlog_base64_flag.test b/mysql-test/suite/binlog/t/binlog_base64_flag.test index 2964b493c5d..d735dd78bcb 100644 --- a/mysql-test/suite/binlog/t/binlog_base64_flag.test +++ b/mysql-test/suite/binlog/t/binlog_base64_flag.test @@ -152,6 +152,8 @@ iONkSBcBAAAAKwAAAMQBAAAQABAAAAAAAAEAA//4AQAAAAMAMTIzAQAAAA== drop table t1, char63_utf8, char128_utf8; +call mtr.add_suppression("Slave SQL.*master suffers from this bug: http:..bugs.mysql.com.bug.php.id=37426.* Error_code: 1105"); +call mtr.add_suppression("Slave SQL.*Table definition on master and slave does not match: Column 1 size mismatch.* Error_code: 1535"); --echo # --echo # Bug #54393: crash and/or valgrind errors in diff --git a/mysql-test/suite/binlog/t/binlog_bug23533.test b/mysql-test/suite/binlog/t/binlog_bug23533.test new file mode 100644 index 00000000000..c05abe788c6 --- /dev/null +++ b/mysql-test/suite/binlog/t/binlog_bug23533.test @@ -0,0 +1,50 @@ +############################################################# +# Bug#23533: CREATE SELECT max_binlog_cache_size test +# case needed +############################################################# + +--source include/have_innodb.inc +--source include/have_log_bin.inc +--source include/have_binlog_format_row.inc + +SET AUTOCOMMIT=0; + +# Create 1st table +CREATE TABLE t1 (a INT NOT NULL AUTO_INCREMENT, b TEXT, PRIMARY KEY(a)) ENGINE=InnoDB; +--disable_query_log +let $i= 1000; +while ($i) +{ + BEGIN; + eval INSERT INTO t1 VALUES($i, REPEAT('x', 4096)); + COMMIT; + dec $i; +} +--enable_query_log +SELECT COUNT(*) FROM t1; + +# Set small value for max_binlog_cache_size +let $saved_binlog_cache_size= query_get_value(SELECT @@binlog_cache_size AS Value, Value, 1); +let $saved_max_binlog_cache_size= query_get_value(SELECT @@max_binlog_cache_size AS Value, Value, 1); +SET GLOBAL binlog_cache_size=4096; +SET GLOBAL max_binlog_cache_size=4096; + +# New value of max_binlog_cache_size will apply to new session +disconnect default; +connect(default,localhost,root,,test); + +# Copied data from t1 into t2 large than max_binlog_cache_size +START TRANSACTION; +--error 1197 +CREATE TABLE t2 SELECT * FROM t1; +COMMIT; +SHOW TABLES LIKE 't%'; + +# 5.1 End of Test +--disable_query_log +eval SET GLOBAL max_binlog_cache_size=$saved_max_binlog_cache_size; +eval SET GLOBAL binlog_cache_size=$saved_binlog_cache_size; +--enable_query_log +DROP TABLE t1; +disconnect default; +connect(default,localhost,root,,test); diff --git a/mysql-test/suite/binlog/t/binlog_bug36391-master.opt b/mysql-test/suite/binlog/t/binlog_bug36391-master.opt new file mode 100644 index 00000000000..56273241f14 --- /dev/null +++ b/mysql-test/suite/binlog/t/binlog_bug36391-master.opt @@ -0,0 +1 @@ +--sql_mode=NO_BACKSLASH_ESCAPES diff --git a/mysql-test/suite/binlog/t/binlog_bug36391.test b/mysql-test/suite/binlog/t/binlog_bug36391.test new file mode 100644 index 00000000000..64d91dfafd9 --- /dev/null +++ b/mysql-test/suite/binlog/t/binlog_bug36391.test @@ -0,0 +1,30 @@ +# +# BUG#36391 and BUG#38731 +# +# The fix for BUG#20103 "Escaping with backslash does not work as expected" +# was implemented too greedy though in that it not only changes the behavior +# of backslashes within strings but in general, so disabling command shortcuts +# like \G or \C (which in turn leads to BUG#36391: "mysqlbinlog creates invalid charset statements". +# +# The test executes simple commands that are stored in the binary log and +# re-execute them through the mysql client which should have to process +# some command shortcuts. The backslashes within strings is disabled in the file +# rpl_bug36391-master.opt by the option --sql_mode=NO_BACKSLASH_ESCAPES. +# +# + +--source include/have_log_bin.inc +--source include/have_binlog_format_mixed.inc + +CREATE TABLE t1(id INT); +let $binlog= query_get_value(SHOW MASTER STATUS, File, 1); +let $binlog_path= `SELECT CONCAT(@@DATADIR, '$binlog')`; +SHOW TABLES; +FLUSH LOGS; +DROP TABLE t1; + +--exec $MYSQL_BINLOG $binlog_path | $MYSQL test +SHOW TABLES; + +# Clean up +DROP TABLE t1; diff --git a/mysql-test/suite/binlog/t/binlog_index.test b/mysql-test/suite/binlog/t/binlog_index.test index c2b8efce57f..86c314e9236 100644 --- a/mysql-test/suite/binlog/t/binlog_index.test +++ b/mysql-test/suite/binlog/t/binlog_index.test @@ -6,6 +6,8 @@ source include/not_embedded.inc; # Don't test this under valgrind, memory leaks will occur --source include/not_valgrind.inc source include/have_debug.inc; +# Avoid CrashReporter popup on Mac +--source include/not_crashrep.inc call mtr.add_suppression('Attempting backtrace'); call mtr.add_suppression('MSYQL_BIN_LOG::purge_logs failed to process registered files that would be purged.'); call mtr.add_suppression('MSYQL_BIN_LOG::open failed to sync the index file'); |