Below is the list of changes that have just been committed into a local
6.0 repository of aelkin. When aelkin does a push these changes
will be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2008-05-01 14:04:33+03:00, aelkin@stripped +2 -0
Bug #35546 mysqlbinlog.cc: Load_log_processor::process_first_event() fails creating unique
Bug #34283 mysqlbinlog leaves tmpfile after termination if binlog contains load data infile
Bug #35543 mysqlbinlog.cc does not properly work with tmp files
There were failures on pb executions in that mysqlbinlog could not compose a new
unique file name of its purpose.
The reason of the bug has been that mysqlbinlog used the system wide temprorary directory instead
of the specified by mtr so that mysqlbinlog's temporary files happened to be out of reach of mtr.
Logics of the mysqlbinlog program correctly allows leaving new produced files such as ones that
hold LOAD DATA data.
This is fine as long as a caller of mysqlbinlog takes care of the new files later.
The problem fixed with specifying explicitly the temp directory for mysqlbinlog when it's called
from mtr. New files mysqlbinlog can produce now reside in the mtr temporary directory.
mysql-test/mysql-test-run.pl@stripped, 2008-05-01 14:04:31+03:00, aelkin@stripped +33 -1
adding --local-load= $opt_tmpdir argument to mysqlbinlog.
mysql-test/suite/binlog/t/binlog_killed_simulate.test@stripped, 2008-05-01 14:04:31+03:00, aelkin@stripped +1 -1
changing to portable macro.
diff -Nrup a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
--- a/mysql-test/mysql-test-run.pl 2008-04-28 11:19:40 +03:00
+++ b/mysql-test/mysql-test-run.pl 2008-05-01 14:04:31 +03:00
@@ -987,6 +987,38 @@ sub client_arguments ($) {
}
+sub mysqlbinlog_arguments ($) {
+ my $tmp_dir= shift;
+ my $exe= mtr_exe_exists("$path_client_bindir/mysqlbinlog");
+
+ my $args;
+ mtr_init_args(\$args);
+ mtr_add_arg($args, "--defaults-file=%s", $path_config_file);
+ if (!($tmp_dir eq ""))
+ {
+ mtr_add_arg($args, "--local-load=%s", $tmp_dir);
+ }
+ client_debug_arg($args, "mysqlbinlog");
+ return mtr_args2str($exe, @$args);
+}
+
+
+sub mysqlbinlog_arguments ($) {
+ my $tmp_dir= shift;
+ my $exe= mtr_exe_exists("$path_client_bindir/mysqlbinlog");
+
+ my $args;
+ mtr_init_args(\$args);
+ mtr_add_arg($args, "--defaults-file=%s", $path_config_file);
+ if (!($tmp_dir eq ""))
+ {
+ mtr_add_arg($args, "--local-load=%s", $tmp_dir);
+ }
+ client_debug_arg($args, "mysqlbinlog");
+ return mtr_args2str($exe, @$args);
+}
+
+
sub mysqlslap_arguments () {
my $exe= mtr_exe_maybe_exists("$path_client_bindir/mysqlslap");
if ( $exe eq "" ) {
@@ -1218,7 +1250,7 @@ sub environment_setup {
$ENV{'MYSQL_SLAP'}= mysqlslap_arguments();
$ENV{'MYSQL_IMPORT'}= client_arguments("mysqlimport");
$ENV{'MYSQL_SHOW'}= client_arguments("mysqlshow");
- $ENV{'MYSQL_BINLOG'}= client_arguments("mysqlbinlog");
+ $ENV{'MYSQL_BINLOG'}= mysqlbinlog_arguments($opt_tmpdir);
$ENV{'MYSQL'}= client_arguments("mysql");
$ENV{'MYSQL_UPGRADE'}= client_arguments("mysql_upgrade");
$ENV{'MYSQLADMIN'}= native_path($exe_mysqladmin);
diff -Nrup a/mysql-test/suite/binlog/t/binlog_killed_simulate.test b/mysql-test/suite/binlog/t/binlog_killed_simulate.test
--- a/mysql-test/suite/binlog/t/binlog_killed_simulate.test 2008-04-08 09:34:29 +03:00
+++ b/mysql-test/suite/binlog/t/binlog_killed_simulate.test 2008-05-01 14:04:31 +03:00
@@ -63,7 +63,7 @@ let $error_code= `select @a like "%#%err
eval select $error_code /* must return 0 to mean the killed query is in */;
# cleanup for the sub-case
-system rm $MYSQLTEST_VARDIR/tmp/binlog_killed_bug27571.binlog;
+remove_file $MYSQLTEST_VARDIR/tmp/binlog_killed_bug27571.binlog;
drop table t1,t2;