summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xusr/local/bin/ping_hosts.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr/local/bin/ping_hosts.sh b/usr/local/bin/ping_hosts.sh
index 7b24fc2..c0de5a1 100755
--- a/usr/local/bin/ping_hosts.sh
+++ b/usr/local/bin/ping_hosts.sh
@@ -75,7 +75,7 @@ for TOPING in $PINGHOSTS ; do
fi
echo Processing $DSTIP
# Look for a service being down
- $PINGCMD -c $COUNT -t 2 $DSTIP
+ $PINGCMD -c $COUNT -S $SRCIP $DSTIP
if [ $? -eq 0 ]; then
# Host is up
# Read in previous status
@@ -104,7 +104,7 @@ for TOPING in $PINGHOSTS ; do
fi
echo "Checking ping time $DSTIP"
# Look at ping values themselves
- PINGTIME=`$PINGCMD -c 1 -t 2 $DSTIP | awk '{ print $7 }' | grep time | cut -d "=" -f2`
+ PINGTIME=`$PINGCMD -c 1 -S $SRCIP $DSTIP | awk '{ print $7 }' | grep time | cut -d "=" -f2`
echo "Ping returned $?"
echo $PINGTIME > /var/db/pingmsstatus/$DSTIP
if [ "$THRESHOLD" != "" ]; then
OpenPOWER on IntegriCloud