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

Fix omr-tracker

This commit is contained in:
Ycarus 2018-08-14 22:03:29 +02:00
parent fb220b9672
commit a95483c34e
2 changed files with 5 additions and 4 deletions

View file

@ -89,6 +89,7 @@ _ping() {
fi fi
return return
} }
echo "Error ping : $ret"
false false
} }
@ -141,7 +142,7 @@ while true; do
OMR_TRACKER_STATUS_MSG="" OMR_TRACKER_STATUS_MSG=""
OMR_TRACKER_LATENCY= OMR_TRACKER_LATENCY=
OMR_TRACKER_TIMEOUT=$((rto / 1000 + (rto % 1000 ? 1 : 0))) OMR_TRACKER_TIMEOUT=$((rto / 1000 + (rto % 1000 ? 1 : 0)))
OMT_TRACKER_LIST_HOSTS="" OMR_TRACKER_LIST_HOSTS=""
if [ -d "/sys/class/net/$OMR_TRACKER_DEVICE" ]; then if [ -d "/sys/class/net/$OMR_TRACKER_DEVICE" ]; then
# retrieve iface ip and gateway # retrieve iface ip and gateway
@ -209,7 +210,7 @@ while true; do
fi fi
fi fi
tries=$((tries - 1)) tries=$((tries - 1))
#OMR_TRACKER_TIMEOUT=$((OMR_TRACKER_TIMEOUT * 2)) OMR_TRACKER_TIMEOUT=$((OMR_TRACKER_TIMEOUT * 2))
_restart _restart
done done
fi fi

View file

@ -8,8 +8,8 @@ config defaults 'defaults'
list hosts '1.0.0.1' list hosts '1.0.0.1'
list hosts '80.67.169.12' list hosts '80.67.169.12'
list hosts '80.67.169.40' list hosts '80.67.169.40'
option timeout '2' option timeout '5'
option tries '5' option tries '3'
option interval '5' option interval '5'
option type 'ping' option type 'ping'
option options '' option options ''