1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

Remove also slave clusters data on restart after test failure

This commit is contained in:
msvensson@shellback.(none)
2006-03-13 11:30:16 +01:00
parent 59e7e3810d
commit 9afc40fccc

View File

@@ -322,6 +322,7 @@ our $opt_ndb_extra_test= 0;
our $exe_ndb_mgm;
our $path_ndb_tools_dir;
our $path_ndb_data_dir;
our $path_ndb_slave_data_dir;
our $file_ndb_testrun_log;
our $flag_ndb_status_ok= 1;
our $flag_ndb_slave_status_ok= 1;
@@ -1148,6 +1149,7 @@ sub executable_setup () {
$exe_slave_mysqld= $exe_slave_mysqld || $exe_mysqld;
$path_ndb_data_dir= "$opt_vardir/ndbcluster-$opt_ndbcluster_port";
$path_ndb_slave_data_dir= "$opt_vardir/ndbcluster-$opt_ndbcluster_port_slave";
$file_ndb_testrun_log= "$opt_vardir/log/ndb_testrun.log";
}
@@ -2321,6 +2323,12 @@ sub restore_installed_db () {
# Remove the ndb_*_fs dirs, forcing a clean start of ndb
rmtree("$path_ndb_data_dir/ndb_1_fs");
rmtree("$path_ndb_data_dir/ndb_2_fs");
if ( $opt_with_ndbcluster_slave )
{
# Remove also the ndb_*_fs dirs for slave cluster
rmtree("$path_ndb_slave_data_dir/ndb_1_fs");
}
}
}
else