ping a client to make sure it is alive before launching a process on it.
This commit is contained in:
parent
3b3e09d992
commit
c79bc6756a
2 changed files with 13 additions and 3 deletions
|
@ -88,7 +88,12 @@ fi
|
||||||
# launch a copy of the client process on each specified machine
|
# launch a copy of the client process on each specified machine
|
||||||
|
|
||||||
for i in $CLIENTS_RUDE; do
|
for i in $CLIENTS_RUDE; do
|
||||||
echo "Launching client process on $i"
|
if ping -c 1 -i 5 $i > /dev/null; then
|
||||||
|
echo "Launching client process on $i"
|
||||||
|
else
|
||||||
|
echo "client $i is currently down, skipping"
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
LOG_FILE="${LOG_DIR}/client-$i.log"
|
LOG_FILE="${LOG_DIR}/client-$i.log"
|
||||||
|
|
||||||
|
@ -104,7 +109,12 @@ for i in $CLIENTS_RUDE; do
|
||||||
done
|
done
|
||||||
|
|
||||||
for i in $CLIENTS_NICE; do
|
for i in $CLIENTS_NICE; do
|
||||||
echo "Launching client process on $i"
|
if ping -c 1 -i 5 $i > /dev/null; then
|
||||||
|
echo "Launching client process on $i"
|
||||||
|
else
|
||||||
|
echo "client $i is currently down, skipping"
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
LOG_FILE="${LOG_DIR}/client-$i.log"
|
LOG_FILE="${LOG_DIR}/client-$i.log"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue