mirror of
https://github.com/Ysurac/openmptcprouter-vps.git
synced 2025-03-09 15:50:00 +00:00
Fix omr-6in4 putting dirty data in log
This commit is contained in:
parent
650638da69
commit
afacd976c8
2 changed files with 7 additions and 7 deletions
|
@ -31,17 +31,17 @@ _ping() {
|
|||
|
||||
while true; do
|
||||
source /etc/shorewall/params.vpn
|
||||
local iface
|
||||
iface=""
|
||||
currentaddr=$(ip addr show omr-6in4 | grep link/sit | awk '{print $2}' | tr -d "\n")
|
||||
currentpeer=$(ip addr show omr-6in4 | grep link/sit | awk '{print $4}' | tr -d "\n")
|
||||
if [ -n "$currentpeer" ]; then
|
||||
_ping $currentpeer
|
||||
status=$?
|
||||
if ! $(exit $status) || [ "$currentpeer" != "$OMR_ADDR" ]; then
|
||||
allip_tcp=$(ip -4 addr show gt-tun0 | grep inet)
|
||||
allip_udp=$(ip -4 addr show gt-udp-tun0 | grep inet)
|
||||
allip_mlvpn=$(ip -4 addr show mlvpn0 | grep inet)
|
||||
allip_openvpn=$(ip -4 addr show tun0 | grep inet)
|
||||
allip_tcp=$(ip -4 addr show gt-tun0 2>/dev/null | grep inet)
|
||||
allip_udp=$(ip -4 addr show gt-udp-tun0 2>/dev/null | grep inet)
|
||||
allip_mlvpn=$(ip -4 addr show mlvpn0 2>/dev/null | grep inet)
|
||||
allip_openvpn=$(ip -4 addr show tun0 2>/dev/null | grep inet)
|
||||
allip="$allip_tcp
|
||||
$allip_udp
|
||||
$allip_openvpn
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue