diff options
author | Sujatha Sivakumar <sujatha.sivakumar@oracle.com> | 2012-05-24 16:25:07 +0530 |
---|---|---|
committer | Sujatha Sivakumar <sujatha.sivakumar@oracle.com> | 2012-05-24 16:25:07 +0530 |
commit | e264eb87ccf29bfd87fcfe606c828d2b407f08c7 (patch) | |
tree | d7a0cd6cc013fd62f633a2f0e4ba18f5c6cca58d /sql/sql_repl.cc | |
parent | 77fcf72cf42f651bf87e3b6300d6d0ccd48b8e9c (diff) | |
download | mariadb-git-e264eb87ccf29bfd87fcfe606c828d2b407f08c7.tar.gz |
Bug#13833962:DISABLE [NOTE] START BINLOG_DUMP TO SLAVE_SERVER(0) MESSAGES
IN THE ERROR LOG
Problem:
Using mysqlbinlog with the --read-from-remote-server option as shown below
prints a message in error log for each call. This happens for 5.5 and above
versions
mysqlbinlog -uroot -p --read-from-remote-server --host=localhost test
Message in error log file is given below:
120312 10:27:57 [Note] Start binlog_dump to slave_server(0), pos(test, 4)
The problem is that it can fill up the error log if the command is called
very often.
Analysis:
The below mentioned print function is called from "mysql_binlog_send" function
which causes the "Start binlog_dump..." string to be printed in error log file.
sql_print_information("Start binlog_dump to master_thread_id(%lu)
slave_server(%d)..."
Fix:
A condition has been added in such a way that the 'sql_print_information'
will be invoked only when the "log_warnings" variable is set to >1
otherwise don't call the 'sql_print_information' function.
Diffstat (limited to 'sql/sql_repl.cc')
-rw-r--r-- | sql/sql_repl.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sql_repl.cc b/sql/sql_repl.cc index ffc7aa4bf8a..5968c17f871 100644 --- a/sql/sql_repl.cc +++ b/sql/sql_repl.cc @@ -476,7 +476,8 @@ void mysql_binlog_send(THD* thd, char* log_ident, my_off_t pos, heartbeat_ts= &heartbeat_buf; set_timespec_nsec(*heartbeat_ts, 0); } - sql_print_information("Start binlog_dump to slave_server(%d), pos(%s, %lu)", + if (global_system_variables.log_warnings > 1) + sql_print_information("Start binlog_dump to slave_server(%d), pos(%s, %lu)", thd->server_id, log_ident, (ulong)pos); if (RUN_HOOK(binlog_transmit, transmit_start, (thd, flags, log_ident, pos))) { |