[MDEV-11095] rpl.rpl_row_mysqlbinlog test fails if row annotation enabled Created: 2016-10-20  Updated: 2019-05-21  Resolved: 2019-05-14

Status: Closed
Project: MariaDB Server
Component/s: Replication
Affects Version/s: 10.1.18, 10.2.2
Fix Version/s: 10.2.25, 10.1.41, 10.3.15, 10.4.5

Type: Bug Priority: Major
Reporter: Nirbhay Choubey (Inactive) Assignee: Sujatha Sivakumar (Inactive)
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-7635 update defaults and simplify mysqld c... Closed

 Description   

How to repeat :

$ perl mtr rpl_row_mysqlbinlog --mysqld=--binlog-annotate-row-events=1
...
rpl.rpl_row_mysqlbinlog 'row'            [ fail ]
        Test ended at 2016-10-20 18:10:44
 
CURRENT_TEST: rpl.rpl_row_mysqlbinlog
--- /home/nirbhay/project/git-repo/mariadb/10.1/install/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result	2016-09-30 09:11:25.000000000 -0400
+++ /home/nirbhay/project/git-repo/mariadb/10.1/install/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.reject	2016-10-20 18:10:44.684210000 -0400
@@ -218,13 +218,13 @@
 include/wait_for_slave_to_start.inc
 SELECT COUNT(*) from t1;
 COUNT(*)
-352
+351
 SELECT COUNT(*) from t2;
 COUNT(*)
-500
+267
 SELECT COUNT(*) from t3;
 COUNT(*)
-500
+267
 SELECT * FROM t1 ORDER BY word LIMIT 5;
 word
 Aarhus
@@ -241,20 +241,20 @@
 5
 SELECT c1, c3, c4, c5  FROM t3 ORDER BY c1 LIMIT 5;
 c1	c3	c4	c5
-1	2006-02-22 00:00:00	Tested in Texas	2.2
-2	2006-02-22 00:00:00	Tested in Texas	4.4
-3	2006-02-22 00:00:00	Tested in Texas	6.6
-4	2006-02-22 00:00:00	Tested in Texas	8.8
-5	2006-02-22 00:00:00	Tested in Texas	11
+234	2006-02-22 00:00:00	Tested in Texas	514.8
+235	2006-02-22 00:00:00	Tested in Texas	517
+236	2006-02-22 00:00:00	Tested in Texas	519.2
+237	2006-02-22 00:00:00	Tested in Texas	521.4
+238	2006-02-22 00:00:00	Tested in Texas	523.6
 SELECT COUNT(*) from t1;
 COUNT(*)
-352
+351
 SELECT COUNT(*) from t2;
 COUNT(*)
-500
+267
 SELECT COUNT(*) from t3;
 COUNT(*)
-500
+267
 SELECT * FROM t1 ORDER BY word LIMIT 5;
 word
 Aarhus
@@ -271,11 +271,11 @@
 5
 SELECT c1, c3, c4, c5  FROM t3 ORDER BY c1 LIMIT 5;
 c1	c3	c4	c5
-1	2006-02-22 00:00:00	Tested in Texas	2.2
-2	2006-02-22 00:00:00	Tested in Texas	4.4
-3	2006-02-22 00:00:00	Tested in Texas	6.6
-4	2006-02-22 00:00:00	Tested in Texas	8.8
-5	2006-02-22 00:00:00	Tested in Texas	11
+234	2006-02-22 00:00:00	Tested in Texas	514.8
+235	2006-02-22 00:00:00	Tested in Texas	517
+236	2006-02-22 00:00:00	Tested in Texas	519.2
+237	2006-02-22 00:00:00	Tested in Texas	521.4
+238	2006-02-22 00:00:00	Tested in Texas	523.6
 --- Test 5 LOAD DATA --

I haven't been able to reduce the test case, but looks like its related to mysqlbinlog's --read-from-remote-server.



 Comments   
Comment by Elena Stepanova [ 2017-01-20 ]

Make sure that the test case is re-enabled when the bug is fixed.

Comment by Sujatha Sivakumar (Inactive) [ 2019-04-02 ]

Hello Andrei,

Please review the fix for MDEV-11095 at following location.

https://github.com/MariaDB/server/commit/c33e89b76774889ed378507634990add7cc05108
http://buildbot.askmonty.org/buildbot/grid?category=main&branch=bb-10.1-sujatha

Comment by Andrei Elkin [ 2019-05-13 ]

Sujatha, thanks for a good analysis and fixes! Andrei.

Comment by Sujatha Sivakumar (Inactive) [ 2019-05-14 ]

Fix has been pushed in 10.1.41.

For 10.2 and above please find the following changes.

MDEV-11095: rpl.rpl_row_mysqlbinlog test fails if row annotation enabled

Enabling the test once again.

Rerecord the result file as default sql_mode has changed after the test
was disabled.

diff --git a/mysql-test/suite/rpl/disabled.def b/mysql-test/suite/rpl/disabled.def
index e37ad842790..e3a6aebb7f3 100644
--- a/mysql-test/suite/rpl/disabled.def
+++ b/mysql-test/suite/rpl/disabled.def
@@ -15,5 +15,4 @@ rpl_get_master_version_and_clock : Bug#11766137 Jan 05 2011 joro Valgrind warnin
 rpl_partition_archive     : MDEV-5077 2013-09-27 svoj Cannot exchange partition with archive table
 rpl_row_binlog_max_cache_size : MDEV-11092
 rpl_blackhole             : MDEV-11094
-rpl_row_mysqlbinlog       : MDEV-11095
 rpl_row_index_choice      : MDEV-11666
diff --git a/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result b/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
index b86743507d8..42d7fc39b5c 100644
--- a/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
+++ b/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
@@ -169,7 +169,7 @@ use `test`/*!*/;
 SET TIMESTAMP=1000000000/*!*/;
 SET @@session.pseudo_thread_id=999999999/*!*/;
 SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1, @@session.check_constraint_checks=1/*!*/;
-SET @@session.sql_mode=1342177280/*!*/;
+SET @@session.sql_mode=1411383296/*!*/;
 SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
 /*!\C latin1 *//*!*/;
 SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
@@ -192,7 +192,7 @@ use `test`/*!*/;
 SET TIMESTAMP=1000000000/*!*/;
 SET @@session.pseudo_thread_id=999999999/*!*/;
 SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1, @@session.check_constraint_checks=1/*!*/;
-SET @@session.sql_mode=1342177280/*!*/;
+SET @@session.sql_mode=1411383296/*!*/;
 SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
 /*!\C latin1 *//*!*/;
 SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
@@ -307,7 +307,7 @@ use `test`/*!*/;
 SET TIMESTAMP=1000000000/*!*/;
 SET @@session.pseudo_thread_id=999999999/*!*/;
 SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1, @@session.check_constraint_checks=1/*!*/;
-SET @@session.sql_mode=1342177280/*!*/;
+SET @@session.sql_mode=1411383296/*!*/;
 SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
 /*!\C latin1 *//*!*/;
 SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
@@ -336,7 +336,7 @@ use `test`/*!*/;
 SET TIMESTAMP=1000000000/*!*/;
 SET @@session.pseudo_thread_id=999999999/*!*/;
 SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1, @@session.check_constraint_checks=1/*!*/;
-SET @@session.sql_mode=1342177280/*!*/;
+SET @@session.sql_mode=1411383296/*!*/;
 SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
 /*!\C latin1 *//*!*/;
 SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
diff --git a/mysql-test/suite/rpl/t/rpl_row_mysqlbinlog.test b/mysql-test/suite/rpl/t/rpl_row_mysqlbinlog.test
index 678679f0cf1..a249043fa19 100644
--- a/mysql-test/suite/rpl/t/rpl_row_mysqlbinlog.test
+++ b/mysql-test/suite/rpl/t/rpl_row_mysqlbinlog.test
@@ -151,8 +151,7 @@ remove_file $MYSQLTEST_VARDIR/tmp/master.sql;
 --exec $MYSQL_BINLOG --short-form --local-load=$MYSQLTEST_VARDIR/tmp/ --stop-position=$stop_position --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001
 
 --echo --- Test 4 Second Remote test --
---exec $MYSQL_BINLOG --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000001 > $MYSQLTEST_VARDIR/tmp/remote.sql
---exec $MYSQL_BINLOG --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT master-bin.000002 >> $MYSQLTEST_VARDIR/tmp/remote.sql
+--exec $MYSQL_BINLOG --read-from-remote-server --user=root --host=127.0.0.1 --port=$MASTER_MYPORT --to-last-log master-bin.000001 > $MYSQLTEST_VARDIR/tmp/remote.sql
 
 # Now that we have our file, lets get rid of the current database.
 # Cleanup the master and the slave and try to recreate.

Comment by Andrei Elkin [ 2019-05-21 ]

Looks good.

Generated at Thu Feb 08 07:47:17 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.