481 |
my $host = $p->{host}; |
my $host = $p->{host}; |
482 |
my $share = $p->{share}; |
my $share = $p->{share}; |
483 |
my $dump = $p->{num}; |
my $dump = $p->{num}; |
484 |
my $otherUser = "backuppc-agi"; |
my $currUser = getlogin(); |
485 |
|
my $otherUser = ""; |
486 |
my $cmd = "sudo -u $otherUser ".$tarIncCreate. " -h $host -s $share -n $dump"; |
if ($currUser eq "agi") { |
487 |
print "$cmd "; |
$otherUser = "backuppc-agi"; |
488 |
if (system($cmd) != 0) { |
} elsif ($currUser eq "qc") { |
489 |
print " FAILED.\n"; |
$otherUser = "backuppc-qc"; |
490 |
} else { |
} |
491 |
print " done.\n"; |
if ($otherUser ne "") { |
492 |
|
my $cmd = "sudo -u $otherUser ".$tarIncCreate. " -h $host -s $share -n $dump"; |
493 |
|
print "$cmd "; |
494 |
|
if (system($cmd) != 0) { |
495 |
|
print " FAILED.\n"; |
496 |
|
} else { |
497 |
|
print " done.\n"; |
498 |
} |
} |
499 |
|
} |
500 |
} |
} |
501 |
|
|
502 |
skip "can't find increment $rel_path, recreateing obviously did not work: $!" unless (-r "$tar_dir/$rel_path"); |
skip "can't find increment $rel_path, recreateing obviously did not work: $!" unless (-r "$tar_dir/$rel_path"); |