mirror of
https://github.com/MariaDB/server.git
synced 2025-01-21 06:22:28 +01:00
Merge neptunus.(none):/home/msvensson/mysql/same_tools/my41-same_tools
into neptunus.(none):/home/msvensson/mysql/same_tools/my50-same_tools
This commit is contained in:
commit
28d4e7c1ae
1 changed files with 31 additions and 38 deletions
|
@ -360,8 +360,8 @@ sub run_testcase_stop_servers ($$$);
|
|||
sub run_testcase_start_servers ($);
|
||||
sub run_testcase_check_skip_test($);
|
||||
sub report_failure_and_restart ($);
|
||||
sub do_before_start_master ($$);
|
||||
sub do_before_start_slave ($$);
|
||||
sub do_before_start_master ($);
|
||||
sub do_before_start_slave ($);
|
||||
sub ndbd_start ($$$);
|
||||
sub ndb_mgmd_start ($);
|
||||
sub mysqld_start ($$$);
|
||||
|
@ -2539,7 +2539,10 @@ EOF
|
|||
;
|
||||
|
||||
print OUT "nonguarded\n" if $instance->{'nonguarded'};
|
||||
if ( $mysql_version_id >= 50100 )
|
||||
{
|
||||
print OUT "log-output=FILE\n" if $instance->{'old_log_format'};
|
||||
}
|
||||
print OUT "\n";
|
||||
}
|
||||
|
||||
|
@ -2866,25 +2869,18 @@ sub report_failure_and_restart ($) {
|
|||
##############################################################################
|
||||
|
||||
|
||||
# The embedded server needs the cleanup so we do some of the start work
|
||||
# but stop before actually running mysqld or anything.
|
||||
sub do_before_start_master ($$) {
|
||||
my $tname= shift;
|
||||
my $init_script= shift;
|
||||
sub do_before_start_master ($) {
|
||||
my ($tinfo)= @_;
|
||||
|
||||
my $tname= $tinfo->{'name'};
|
||||
my $init_script= $tinfo->{'master_sh'};
|
||||
|
||||
# FIXME what about second master.....
|
||||
|
||||
# Remove stale binary logs except for 2 tests which need them FIXME here????
|
||||
if ( $tname ne "rpl_crash_binlog_ib_1b" and
|
||||
$tname ne "rpl_crash_binlog_ib_2b" and
|
||||
$tname ne "rpl_crash_binlog_ib_3b")
|
||||
{
|
||||
# FIXME we really want separate dir for binlogs
|
||||
foreach my $bin ( glob("$opt_vardir/log/master*-bin*") )
|
||||
{
|
||||
unlink($bin);
|
||||
}
|
||||
}
|
||||
|
||||
# FIXME only remove the ones that are tied to this master
|
||||
# Remove old master.info and relay-log.info files
|
||||
|
@ -2903,30 +2899,22 @@ sub do_before_start_master ($$) {
|
|||
# mtr_warning("$init_script exited with code $ret");
|
||||
}
|
||||
}
|
||||
# for gcov FIXME needed? If so we need more absolute paths
|
||||
# chdir($glob_basedir);
|
||||
}
|
||||
|
||||
|
||||
sub do_before_start_slave ($$) {
|
||||
my $tname= shift;
|
||||
my $init_script= shift;
|
||||
sub do_before_start_slave ($) {
|
||||
my ($tinfo)= @_;
|
||||
|
||||
my $tname= $tinfo->{'name'};
|
||||
my $init_script= $tinfo->{'master_sh'};
|
||||
|
||||
# Remove stale binary logs and old master.info files
|
||||
# except for too tests which need them
|
||||
if ( $tname ne "rpl_crash_binlog_ib_1b" and
|
||||
$tname ne "rpl_crash_binlog_ib_2b" and
|
||||
$tname ne "rpl_crash_binlog_ib_3b" )
|
||||
{
|
||||
# FIXME we really want separate dir for binlogs
|
||||
foreach my $bin ( glob("$opt_vardir/log/slave*-bin*") )
|
||||
{
|
||||
unlink($bin);
|
||||
}
|
||||
# FIXME really master?!
|
||||
|
||||
unlink("$slave->[0]->{'path_myddir'}/master.info");
|
||||
unlink("$slave->[0]->{'path_myddir'}/relay-log.info");
|
||||
}
|
||||
|
||||
# Run slave initialization shell script if one exists
|
||||
if ( $init_script )
|
||||
|
@ -3068,8 +3056,13 @@ sub mysqld_arguments ($$$$$) {
|
|||
# Directory where slaves find the dumps generated by "load data"
|
||||
# on the server. The path need to have constant length otherwise
|
||||
# test results will vary, thus a relative path is used.
|
||||
my $slave_load_path= "../tmp";
|
||||
if ( $mysql_version_id < 50000 )
|
||||
{
|
||||
$slave_load_path= "../../var/tmp";
|
||||
}
|
||||
mtr_add_arg($args, "%s--slave-load-tmpdir=%s", $prefix,
|
||||
"../tmp");
|
||||
$slave_load_path);
|
||||
mtr_add_arg($args, "%s--socket=%s", $prefix,
|
||||
$slave->[$idx]->{'path_sock'});
|
||||
mtr_add_arg($args, "%s--set-variable=slave_net_timeout=10", $prefix);
|
||||
|
@ -3682,7 +3675,7 @@ sub run_testcase_start_servers($) {
|
|||
if ( !$master->[0]->{'pid'} )
|
||||
{
|
||||
# Master mysqld is not started
|
||||
do_before_start_master($tname,$tinfo->{'master_sh'});
|
||||
do_before_start_master($tinfo);
|
||||
|
||||
mysqld_start($master->[0],$tinfo->{'master_opt'},[]);
|
||||
|
||||
|
@ -3747,7 +3740,7 @@ sub run_testcase_start_servers($) {
|
|||
|
||||
restore_slave_databases($tinfo->{'slave_num'});
|
||||
|
||||
do_before_start_slave($tname,$tinfo->{'slave_sh'});
|
||||
do_before_start_slave($tinfo);
|
||||
|
||||
if ( ! $opt_skip_ndbcluster_slave and
|
||||
!$clusters->[1]->{'pid'} and
|
||||
|
|
Loading…
Reference in a new issue