diff options
author | Sven Sandberg <sven.sandberg@oracle.com> | 2011-03-25 15:16:13 +0100 |
---|---|---|
committer | Sven Sandberg <sven.sandberg@oracle.com> | 2011-03-25 15:16:13 +0100 |
commit | f1b638d33cdf95b70fa925cce304864c96fdf7ee (patch) | |
tree | 2b5fa95c1dfd66757d984c5d237e2ff8432bd415 /mysql-test/r/mysqlbinlog.result | |
parent | 5af973582dcec824411f2d43bf41d38d8298abf3 (diff) | |
download | mariadb-git-f1b638d33cdf95b70fa925cce304864c96fdf7ee.tar.gz |
BUG#11766427, BUG#59539: Filter by server id in mysqlbinlog fails
Problem: mysqlbinlog --server-id may filter out Format_description_log_events.
If mysqlbinlog does not process the Format_description_log_event,
then mysqlbinlog cannot read the rest of the binary log correctly.
This can have the effect that mysqlbinlog crashes, generates an error,
or generates output that causes mysqld to crash, generate an error,
or corrupt data.
Fix: Never filter out Format_description_log_events. Also, never filter
out Rotate_log_events.
client/mysqlbinlog.cc:
Process Format_description_log_events even when the
server_id does not match the number given by --server-id.
mysql-test/t/mysqlbinlog.test:
Add test case.
Diffstat (limited to 'mysql-test/r/mysqlbinlog.result')
-rw-r--r-- | mysql-test/r/mysqlbinlog.result | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/r/mysqlbinlog.result b/mysql-test/r/mysqlbinlog.result index 1f2e1ed67e0..45068ddfaec 100644 --- a/mysql-test/r/mysqlbinlog.result +++ b/mysql-test/r/mysqlbinlog.result @@ -658,3 +658,15 @@ master-bin.000002 # Query # # CREATE DATABASE test1 master-bin.000002 # Query # # use `test1`; CREATE TABLE t1(id int) master-bin.000002 # Query # # use `test1`; DROP TABLE t1 master-bin.000002 # Query # # DROP DATABASE test1 +RESET MASTER; +USE test; +CREATE TABLE t1 (a INT); +SET GLOBAL SERVER_ID = 2; +DROP TABLE t1; +FLUSH LOGS; +SHOW TABLES IN test; +Tables_in_test +t1 +SHOW TABLES IN test; +Tables_in_test +SET GLOBAL SERVER_ID = 1; |