Commit 7b93194c authored by Magnus Svensson's avatar Magnus Svensson

WL#4189 mtr.pl v2

 - Don't save ndb_*_fs directory after test failure
parent f4ea7624
......@@ -3632,6 +3632,17 @@ sub save_datadir_after_failure($$) {
}
sub remove_ndbfs_from_ndbd_datadir {
my ($ndbd_datadir)= @_;
# Remove the ndb_*_fs directory from ndbd.X/ dir
foreach my $ndbfs_dir ( glob("$ndbd_datadir/ndb_*_fs") )
{
next unless -d $ndbfs_dir; # Skip if not a directory
rmtree($ndbfs_dir);
}
}
sub after_failure ($) {
my ($tinfo)= @_;
......@@ -3657,6 +3668,14 @@ sub after_failure ($) {
if ( clusters() ) {
foreach my $cluster ( clusters() ) {
my $cluster_dir= "$opt_vardir/".$cluster->{name};
# Remove the fileystem of each ndbd
foreach my $ndbd ( in_cluster($cluster, ndbds()) )
{
my $ndbd_datadir= $ndbd->value("DataDir");
remove_ndbfs_from_ndbd_datadir($ndbd_datadir);
}
save_datadir_after_failure($cluster_dir, $save_dir);
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment