summaryrefslogtreecommitdiffstats
path: root/usr/local/bin
diff options
context:
space:
mode:
authorjeandebogue <jeandebogue@msn.com>2012-02-21 08:55:49 +0100
committerjeandebogue <jeandebogue@msn.com>2012-02-21 08:55:49 +0100
commitd4e37b2edd51ccc39e5d6f912d8079b3d447ee7b (patch)
tree9dafd24be84026d91b084d92f922bab3045f05e6 /usr/local/bin
parent1d50d8d9e96baa18cf8998d7756a3cca95789ef7 (diff)
downloadpfsense-d4e37b2edd51ccc39e5d6f912d8079b3d447ee7b.zip
pfsense-d4e37b2edd51ccc39e5d6f912d8079b3d447ee7b.tar.gz
Remove the -S $SRCIP to ping and added a timeout.
Diffstat (limited to 'usr/local/bin')
-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 c0de5a1..7b24fc2 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 -S $SRCIP $DSTIP
+ $PINGCMD -c $COUNT -t 2 $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 -S $SRCIP $DSTIP | awk '{ print $7 }' | grep time | cut -d "=" -f2`
+ PINGTIME=`$PINGCMD -c 1 -t 2 $DSTIP | awk '{ print $7 }' | grep time | cut -d "=" -f2`
echo "Ping returned $?"
echo $PINGTIME > /var/db/pingmsstatus/$DSTIP
if [ "$THRESHOLD" != "" ]; then
OpenPOWER on IntegriCloud