marsadm: fix sync check

This commit is contained in:
Thomas Schoebel-Theuer 2014-09-25 23:06:43 +02:00
parent c2a17bd641
commit 34ea0c53f3
1 changed files with 3 additions and 2 deletions

View File

@ -1791,8 +1791,9 @@ sub primary_phase0 {
if ($cmd eq "primary") {
check_sync_finished($res, $host);
# also check that other secondaries won't loose their sync primary
foreach my $peer (glob("$mars/resource-$res/data-*")) {
$peer =~ m:/data-(.+):;
foreach my $name (glob("$mars/resource-$res/data-*")) {
$name =~ m:/data-(.+):;
my $peer = $1;
next if ($peer eq $old || $peer eq $host);
check_sync_finished($res, $peer);
}