Commit 4aba2e66 authored by Jonathon Duerig's avatar Jonathon Duerig

Various fixes. Notably, pssh needs to be run in interactive mode or it just...

Various fixes. Notably, pssh needs to be run in interactive mode or it just hangs mysteriously while you beat your head against your keyboard trying to understand why.
parent 667b596f
#!/usr/bin/perl -w
use File::Temp qw/ tempfile /;
if (scalar(@ARGV) < 5) {
print STDERR 'run-standalone <run-level> <run-path> <var-path> <log-path> <host-list> [node-list]
......@@ -30,15 +32,16 @@ be a single unqualified name (like node-0).
($level, $runpath, $varpath, $logpath, $hosts, $nodes) = @ARGV;
open HOSTS, ">hosts.txt";
($fh, $filename) = tempfile();
@hostList = split(",", $hosts);
print HOSTS join("\n", @hostList);
close HOSTS;
print $fh join("\n", @hostList);
close $fh;
if (! defined($nodes)) {
$nodes = $hosts;
}
$command = "pssh -h hosts.txt -o out -e err -t 3000 sh $runpath/standalone.sh $level $runpath $varpath $logpath $nodes";
$command = "sh -i -c 'pssh -h $filename -o out -e err -t 3000 sh $runpath/standalone.sh $level $runpath $varpath $logpath $nodes'";
print($command."\n");
system($command);
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