1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-02-15 03:51:51 +00:00

Update to iputils-ping

This commit is contained in:
Ycarus 2018-08-23 14:49:42 +02:00
parent e084e0920c
commit 5cd9511df6
2 changed files with 5 additions and 4 deletions

View file

@ -79,11 +79,11 @@ _ping() {
local host=$1 local host=$1
local deviceip=$2 local deviceip=$2
local localip=$3 local localip=$3
ret=$(ping "${host}" \ ret=$(ping -I "${deviceip}" \
-I "${deviceip}" \ -w "$OMR_TRACKER_TIMEOUT" \
-W "$OMR_TRACKER_TIMEOUT" \
-c 1 \ -c 1 \
-q -q \
"${host}"
) && echo "$ret" | grep -sq "0% packet loss" && { ) && echo "$ret" | grep -sq "0% packet loss" && {
if [ "$localip" = "yes" ]; then if [ "$localip" = "yes" ]; then
OMR_TRACKER_LATENCY=$(echo "$ret" | cut -d "/" -s -f4 | cut -d "." -f1) OMR_TRACKER_LATENCY=$(echo "$ret" | cut -d "/" -s -f4 | cut -d "." -f1)

View file

@ -41,6 +41,7 @@ MY_DEPENDS := \
iftop \ iftop \
tcpdump \ tcpdump \
ethtool \ ethtool \
iputils-ping \
tracebox \ tracebox \
luci-proto-3g \ luci-proto-3g \
comgt-ncm luci-proto-ncm \ comgt-ncm luci-proto-ncm \