From ed7c5dae44512176916fe46ed81ef8df79161e2d Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 11:10:20 +0100 Subject: [PATCH 01/14] Better max metric calculation --- mptcp/files/etc/init.d/mptcp | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/mptcp/files/etc/init.d/mptcp b/mptcp/files/etc/init.d/mptcp index 9f0db4286..ee8027b05 100755 --- a/mptcp/files/etc/init.d/mptcp +++ b/mptcp/files/etc/init.d/mptcp @@ -48,13 +48,29 @@ interface_macaddr_count() { interface_max_metric() { local config="$1" - config_get metric "$config" metric - if [ "$metric" = "$count" ]; then - count=$((count+1)) - config_set "$config" metric $count - fi - if [ "$metric" -gt "$count" ]; then - count=$metric + if [ "$1" != "omrvpn" ] && [ "$1" != "omr6in4" ]; then + config_get metric "$config" metric + if [ "$metric" = "$count" ]; then + count=$((count+1)) + config_set "$config" metric $count + fi + if [ "$metric" -gt "$count" ]; then + count=$metric + fi + elif [ "$1" = "omrvpn" ]; then + uci -q batch <<-EOF >/dev/null + set network.${config}.metric=1200 + commit network + set openmptcprouter.${config}.metric=1200 + commit openmptcprouter + EOF + elif [ "$1" = "omr6in4" ]; then + uci -q batch <<-EOF >/dev/null + set network.${config}.metric=1201 + commit network + set openmptcprouter.${config}.metric=1201 + commit openmptcprouter + EOF fi } From a8d46c5f9722879f4406ae98657e4722f7a6b58e Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 11:10:49 +0100 Subject: [PATCH 02/14] Run openmptcprouter-vps every hours --- .../usr/share/omr/post-tracking.d/post-tracking | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking index 15d729cec..a7ca34d0d 100755 --- a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking +++ b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking @@ -247,10 +247,12 @@ disable_pihole() { if [ -n "$(uci -q get dhcp.@dnsmasq[0].server | grep '#53' | grep '10.2')" ]; then _log "Disable Pi-Hole..." uci -q del_list dhcp.@dnsmasq[0].server="$(uci -q get dhcp.@dnsmasq[0].server | tr ' ' '\n' | grep '#53' | grep '10.2')" - uci -q batch <<-EOF >/dev/null - add_list dhcp.@dnsmasq[0].server='127.0.0.1#5353' - commit dhcp - EOF + if [ -z "$(uci -q get dhcp.@dnsmasq[0].server | grep '127.0.0.1#5353')" ]; then + uci -q batch <<-EOF >/dev/null + add_list dhcp.@dnsmasq[0].server='127.0.0.1#5353' + commit dhcp + EOF + fi /etc/init.d/dnsmasq restart fi } @@ -728,7 +730,12 @@ if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.lc)" = "" ] || [ $(($( else [ "$(uci -q get openmptcprouter.settings.debug)" = "true" ] && _log "Get status and settings for $OMR_TRACKER_INTERFACE... Done" uci -q commit openmptcprouter - #/etc/init.d/openmptcprouter-vps restart >/dev/null 2>&1 + if [ "$(pgrep openmptcprouter-vps)" = "" ] && ( [ "$(uci -q get openmptcprouter.settings.apilc)" = "" ] || [ $(($(date +"%s") - $(uci -q get openmptcprouter.settings.apilc))) -gt 3600 ] ); then + _log "Check API configuration..." + /etc/init.d/openmptcprouter-vps restart >/dev/null 2>&1 + uci -q set openmptcprouter.settings.apilc=$(date +"%s") + _log "Check API configuration... Done" + fi fi dns_flush fi From 3b2bf7ba598f47e0854d3f04098613eacaa33458 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 13:34:42 +0100 Subject: [PATCH 03/14] Remove tcp_retries2 default --- shadowsocks-libev/files/shadowsocks.conf | 1 - 1 file changed, 1 deletion(-) diff --git a/shadowsocks-libev/files/shadowsocks.conf b/shadowsocks-libev/files/shadowsocks.conf index 1c4703f5b..159ea3860 100644 --- a/shadowsocks-libev/files/shadowsocks.conf +++ b/shadowsocks-libev/files/shadowsocks.conf @@ -51,5 +51,4 @@ net.ipv4.tcp_mtu_probing = 0 net.netfilter.nf_conntrack_max = 131072 net.ipv4.tcp_ecn = 1 -net.ipv4.tcp_retries2 = 10 #net.ipv4.tcp_sack = 0 From ef58af317fb81dbbc80aa4ad176f50eced3c0448 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 15:31:33 +0100 Subject: [PATCH 04/14] Fix MPTCP interface trigger --- mptcp/files/etc/init.d/mptcp | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/mptcp/files/etc/init.d/mptcp b/mptcp/files/etc/init.d/mptcp index ee8027b05..57e4fa63d 100755 --- a/mptcp/files/etc/init.d/mptcp +++ b/mptcp/files/etc/init.d/mptcp @@ -470,17 +470,13 @@ reload_service() { return 0 } -add_interface_trigger() { - local interface ignore - - config_get interface "$1" interface - config_get_bool ignore "$1" ignore 0 - - [ -n "$interface" -a $ignore -eq 0 ] && procd_add_interface_trigger "interface.*" "$interface" /etc/init.d/mptcp reload -} +service_triggers_load_interface() { is_supported_interface "$1" && ifaces="${ifaces}${1} "; } service_triggers() { + local ifaces n + config_load network; config_foreach service_triggers_load_interface 'interface'; procd_add_reload_trigger "network" - config_load network - config_foreach add_interface_trigger interface + procd_open_trigger + for n in $ifaces; do procd_add_reload_interface_trigger "$n"; procd_add_interface_trigger "interface.*" "$n" /etc/init.d/mptcp reload; done; + procd_close_trigger } From abaadfdc6b556b828285899a4fa37136cee09f79 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 15:32:55 +0100 Subject: [PATCH 05/14] Add a sleep between omr-tracker interface run --- omr-tracker/files/etc/init.d/omr-tracker | 1 + 1 file changed, 1 insertion(+) diff --git a/omr-tracker/files/etc/init.d/omr-tracker b/omr-tracker/files/etc/init.d/omr-tracker index 5d470808b..e0d78e5ae 100755 --- a/omr-tracker/files/etc/init.d/omr-tracker +++ b/omr-tracker/files/etc/init.d/omr-tracker @@ -78,6 +78,7 @@ _launch_tracker() { procd_set_param respawn 0 10 0 procd_set_param stderr 1 procd_close_instance + sleep $((RANDOM % 10)) } _launch_server_tracker() { From 28b13c78e9bcede9aefa2ef97f22619149bf2341 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Tue, 17 Nov 2020 15:33:22 +0100 Subject: [PATCH 06/14] Only display real interface in wizard --- .../luasrc/view/openmptcprouter/wizard.htm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm b/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm index 0ee9ad9a2..51e13edba 100644 --- a/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm +++ b/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm @@ -14,7 +14,8 @@ local ifacename = uci:get("network",ifacen,"ifname") local ifacetype = uci:get("network",ifacen,"type") or "" local ifaceproto = uci:get("network",ifacen,"proto") or "" - if ifacename == dev and (ifacetype == "macvlan" or ifacetype == "bridge" or ifaceproto == "6in4") then + --if ifacename == dev and (ifacetype == "macvlan" or ifacetype == "bridge" or ifaceproto == "6in4") then + if ifacename == dev and (ifacetype == "macvlan" or ifaceproto == "6in4") then return false end end @@ -380,7 +381,7 @@ <% iffind=0 for _, ifacea in ipairs(ifaces) do - if not (ifacea == "lo" or ifacea == "6in4-omr6in4" or ifacea == "mlvpn0" or ifacea:match("^ifb.*") or ifacea:match("^sit.*") or ifacea:match("^gre.*") or ifacea:match("^ip6.*") or ifacea:match("^teql.*") or ifacea:match("^erspan.*") or ifacea:match("^tun.*")) then + if not (ifacea == "lo" or ifacea == "6in4-omr6in4" or ifacea == "mlvpn0" or ifacea:match("^ifb.*") or ifacea:match("^sit.*") or ifacea:match("^gre.*") or ifacea:match("^ip6.*") or ifacea:match("^teql.*") or ifacea:match("^erspan.*") or ifacea:match("^tun.*")) and device_notvirtual(ifacea) then if uci:get("network",ifname,"proto") ~= "macvlan" then %> @@ -485,7 +486,7 @@ <% for _, ifacea in ipairs(ifaces) do - if not (ifacea == "lo" or ifacea == "6in4-omr6in4" or ifacea == "mlvpn0" or ifacea:match("^ifb.*") or ifacea:match("^sit.*") or ifacea:match("^gre.*") or ifacea:match("^ip6.*") or ifacea:match("^teql.*") or ifacea:match("^erspan.*")) then + if not (ifacea == "lo" or ifacea == "6in4-omr6in4" or ifacea == "mlvpn0" or ifacea:match("^ifb.*") or ifacea:match("^sit.*") or ifacea:match("^gre.*") or ifacea:match("^ip6.*") or ifacea:match("^teql.*") or ifacea:match("^erspan.*")) and device_notvirtual(ifacea) then %> <% From e95f1a1cd90a8beec6ec97808bb527bb85d4006a Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:24:11 +0100 Subject: [PATCH 07/14] Update Glorytun UDP --- glorytun-udp/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/glorytun-udp/Makefile b/glorytun-udp/Makefile index 121af0912..c2dd9da15 100644 --- a/glorytun-udp/Makefile +++ b/glorytun-udp/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/angt/glorytun.git -PKG_SOURCE_VERSION:=97607fdf5c6c33df512ed85190a1fd93b5f45e77 +PKG_SOURCE_VERSION:=32267e86a6da05b285bb3bf2b136c105dc0af4bb PKG_NAME:=glorytun-udp PKG_VERSION:=0.3.4-$(PKG_SOURCE_VERSION) PKG_RELEASE:=23 From b628a7c92d522cc46bf155d1ed16309906f53df5 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:24:29 +0100 Subject: [PATCH 08/14] Update path options for glorytun UDP --- .../share/omr/post-tracking.d/post-tracking | 38 +++++++------------ 1 file changed, 14 insertions(+), 24 deletions(-) diff --git a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking index a7ca34d0d..9c3c9063a 100755 --- a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking +++ b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking @@ -318,7 +318,7 @@ if [ "$OMR_TRACKER_STATUS" = "ERROR" ] || [ "$interface_up" != "true" ]; then # multipath "$OMR_TRACKER_DEVICE" off > /dev/null 2>&1 #fi if [ -n "$OMR_TRACKER_DEVICE_IP" ]; then - glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set down > /dev/null 2>&1 + glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set down > /dev/null 2>&1 fi if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.vpn)" = "1" ]; then VPN_BASE_INTF="$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.baseintf)" @@ -561,7 +561,7 @@ if [ -n "$OMR_TRACKER_DEVICE_IP" ] && [ -n "$OMR_TRACKER_DEVICE_GATEWAY" ]; then fi fi -[ "$multipath_config" = "on" ] && { +if [ "$multipath_config" = "on" ] || [ "$multipath_config" = "backup" ]; then download="$(uci -q get network.$OMR_TRACKER_INTERFACE.downloadspeed)" [ -z "$download" ] && download="$(uci -q get sqm.$OMR_TRACKER_INTERFACE.download)" upload="$(uci -q get network.$OMR_TRACKER_INTERFACE.uploadspeed)" @@ -569,38 +569,28 @@ fi if [ "$(uci -q show | grep mptcpr)" = "" ]; then touch /etc/config/openmptcprouter fi - if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.vpn)" != "1" ] && [ "$(pgrep glorytun-udp)" != "" ] && ([ "$(glorytun-udp path | grep $OMR_TRACKER_DEVICE_IP)" = "" ] || [ "$(glorytun-udp path $OMR_TRACKER_DEVICE_IP | awk '{print $13}')" = "0" ] || [ "$(glorytun-udp path $OMR_TRACKER_DEVICE_IP | awk '{print $16}')" = "0" ]); then + gtudpst="up" + [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.multipathvpn)" != "1" ] && [ "$multipath_config" = "backup" ] && [ "$(pgrep glorytun-udp)" != "" ] && gtudpst="backup" + if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.vpn)" != "1" ] && [ "$(pgrep glorytun-udp)" != "" ] && [ "$(glorytun-udp path | grep $OMR_TRACKER_DEVICE_IP)" = "" ]; then if [ "$download" != "0" ] && [ "$download" != "" ] && [ "$upload" != "0" ] && [ "$upload" != "" ]; then if [ "$(uci -q get glorytun.vpn.rateauto)" = "1" ]; then - glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set up rate auto tx $((upload*1000/8)) rx $((download*1000/8)) > /dev/null 2>&1 + glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set up rate auto tx $((upload*1000/8)) rx $((download*1000/8)) > /dev/null 2>&1 else - glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set up rate fixed tx $((upload*1000/8)) rx $((download*1000/8)) > /dev/null 2>&1 + glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set up rate fixed tx $((upload*1000/8)) rx $((download*1000/8)) > /dev/null 2>&1 fi else if [ "$(uci -q get glorytun.vpn.rateauto)" = "1" ]; then - glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set up rate auto tx 12500000 rx 12500000 > /dev/null 2>&1 + glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set up rate auto tx 12500000 rx 12500000 > /dev/null 2>&1 else - glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set up rate fixed tx 12500000 rx 12500000 > /dev/null 2>&1 + glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set up rate fixed tx 12500000 rx 12500000 > /dev/null 2>&1 fi fi fi -# if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.vpn)" = "1" ] && [ "$(pgrep glorytun-udp)" != "" ] && ([ "$(glorytun-udp path | grep $OMR_TRACKER_DEVICE_IP)" = "" ] || [ "$(glorytun-udp path $OMR_TRACKER_DEVICE_IP | awk '{print $13}')" = "0" ] || [ "$(glorytun-udp path $OMR_TRACKER_DEVICE_IP | awk '{print $16}')" = "0" ]); then -# if [ "$download" != "0" ] && [ "$download" != "" ] && [ "$upload" != "0" ] && [ "$upload" != "" ]; then -# if [ "$(uci -q get glorytun.vpn.rateauto)" = "1" ]; then -# glorytun-udp path $OMR_TRACKER_DEVICE_IP to 10.255.250.1 $(uci -q get glorytun.vpn.port) dev tun0 set up rate auto tx ${upload}000 rx ${download}000 > /dev/null 2>&1 -# else -# glorytun-udp path $OMR_TRACKER_DEVICE_IP to 10.255.250.1 $(uci -q get glorytun.vpn.port) dev tun0 set up rate fixed tx ${upload}000 rx ${download}000 > /dev/null 2>&1 -# fi -# else -# if [ "$(uci -q get glorytun.vpn.rateauto)" = "1" ]; then -# glorytun-udp path $OMR_TRACKER_DEVICE_IP to 10.255.250.1 $(uci -q get glorytun.vpn.port) dev tun0 set up rate auto tx 125000000 rx 125000000 > /dev/null 2>&1 -# else -# glorytun-udp path $OMR_TRACKER_DEVICE_IP to 10.255.250.1 $(uci -q get glorytun.vpn.port) dev tun0 set up rate fixed tx 125000000 rx 125000000 > /dev/null 2>&1 -# fi -# fi -# fi -} -[ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.multipathvpn)" != "1" ] && [ "$multipath_config" = "backup" ] && [ "$(pgrep glorytun-udp)" != "" ] && glorytun-udp path $OMR_TRACKER_DEVICE_IP dev tun0 set backup rate auto rx 125000000 tx 125000000 > /dev/null 2>&1 + if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.vpn)" != "1" ] && [ "$(pgrep glorytun-udp)" != "" ] && [ "$(glorytun-udp set | grep 'kxtimeout 7d')" = "" ]; then + glorytun-udp set dev tun0 kxtimeout 7d > /dev/null 2>&1 + fi + [ "$multipath_config" = "backup" ] && [ "$(pgrep glorytun-udp)" != "" ] && glorytun-udp path addr $OMR_TRACKER_DEVICE_IP dev tun0 set pref 500 > /dev/null 2>&1 +fi [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.multipathvpn)" != "1" ] && { [ "$multipath_status" = "$multipath_config" ] || { if [ "$(sysctl -n net.mptcp.mptcp_enabled | tr -d '\n')" = "1" ]; then From bb5c71a8ca7214e51ef47df963a0c2dc75fc7566 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:24:51 +0100 Subject: [PATCH 09/14] Fixed sleep between wan tracker --- omr-tracker/files/etc/init.d/omr-tracker | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/omr-tracker/files/etc/init.d/omr-tracker b/omr-tracker/files/etc/init.d/omr-tracker index e0d78e5ae..e7bf920a7 100755 --- a/omr-tracker/files/etc/init.d/omr-tracker +++ b/omr-tracker/files/etc/init.d/omr-tracker @@ -78,7 +78,7 @@ _launch_tracker() { procd_set_param respawn 0 10 0 procd_set_param stderr 1 procd_close_instance - sleep $((RANDOM % 10)) + sleep 1 } _launch_server_tracker() { From 8e639fd4a58332549bfe746b6d5f02d6f1caaa6b Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:25:16 +0100 Subject: [PATCH 10/14] Fix find IP for omr-test-speed --- openmptcprouter/files/bin/omr-test-speed | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter/files/bin/omr-test-speed b/openmptcprouter/files/bin/omr-test-speed index bc3efae22..fb433b625 100755 --- a/openmptcprouter/files/bin/omr-test-speed +++ b/openmptcprouter/files/bin/omr-test-speed @@ -27,7 +27,7 @@ if [ -z "$INTERFACE" ]; then curl -4 $HOST >/dev/null || echo else domain=$(echo $HOST | awk -F/ '{print $3}') - hostip=$(dig +short A $domain | tr -d "\n") + hostip=$(dig +nocmd +noall +answer A $domain | grep -v CNAME | awk '{print $5}' | tr -d "\n") ipset add ss_rules_dst_bypass_all $hostip curl -4 $HOST >/dev/null || echo ipset del ss_rules_dst_bypass_all $hostip From a8c0cd050274aa7dd00020d2feb5994eebc72c05 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:25:44 +0100 Subject: [PATCH 11/14] Fix find IP for omr-bypass domains bypass --- luci-app-omr-bypass/root/etc/init.d/omr-bypass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/luci-app-omr-bypass/root/etc/init.d/omr-bypass b/luci-app-omr-bypass/root/etc/init.d/omr-bypass index 8e5a0c5bd..3708a0fce 100755 --- a/luci-app-omr-bypass/root/etc/init.d/omr-bypass +++ b/luci-app-omr-bypass/root/etc/init.d/omr-bypass @@ -56,12 +56,12 @@ _bypass_domain() { domain=$(echo $domain | sed 's:^\.::') #logger -t "omr-bypass" "Get IPs of $domain..." if [ -z $RELOAD ]; then - resolve=$(dig a +timeout=1 +tries=1 +nocmd +noall +answer $domain | awk '{print $5}') + resolve=$(dig a +timeout=1 +tries=1 +nocmd +noall +answer $domain | grep -v CNAME | awk '{print $5}') for ip in $resolve; do _bypass_ip $ip $intf done if [ "$disableipv6" = "0" ]; then - resolve=$(dig aaaa +timeout=1 +tries=1 +nocmd +noall +answer $domain | awk '{print $5}') + resolve=$(dig aaaa +timeout=1 +tries=1 +nocmd +noall +answer $domain | grep AAAA | awk '{print $5}') for ip in $resolve; do _bypass_ip $ip $intf done From b75d5d31178f4a6bccf70bb6964013f5694e70c9 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Nov 2020 19:26:06 +0100 Subject: [PATCH 12/14] Add hwinfo and dmidecode by default --- openmptcprouter-full/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/openmptcprouter-full/Makefile b/openmptcprouter-full/Makefile index eace2e5bd..8afa8bbcb 100644 --- a/openmptcprouter-full/Makefile +++ b/openmptcprouter-full/Makefile @@ -79,7 +79,8 @@ MY_DEPENDS := \ kmod-rt2800-usb kmod-rtl8xxxu kmod-rtl8192cu kmod-net-rtl8192su \ !TARGET_mvebu:luci-proto-qmi wpad-basic kmod-mt7601u kmod-rtl8187 \ luci-app-mlvpn mlvpn 464xlat !TARGET_mvebu:kmod-usb-net-smsc75xx kmod-zram kmod-swconfig swconfig kmod-ipt-nat kmod-ipt-nat6 luci-app-https-dns-proxy kmod-tcp-nanqinlang iptables-mod-ipopt igmpproxy ss iptraf-ng \ - luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim kmod-rtl8xxxu kmod-ath9k-htc luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-wolfssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf + luci-app-acl block-mount blockd fstools luci-app-shutdown libwebp luci-proto-gre tcptraceroute luci-proto-mbim kmod-rtl8xxxu kmod-ath9k-htc luci-app-ttyd luci-mod-dashboard (TARGET_x86||TARGET_x86_64):rtl8192eu-firmware kmod-usb2 libustream-wolfssl (TARGET_x86||TARGET_x86_64):kmod-ixgbevf \ + hwinfo (TARGET_x86||TARGET_x86_64):dmidecode # luci-theme-bootstrap luci-theme-openwrt-2020 luci-theme-openwrt luci-app-status # luci-proto-bonding luci-app-statistics luci-proto-gre # softethervpn5-client softethervpn5-server luci-app-nginx-ha From cf11d7ccbc514ab2864412f70c03891cc62b0103 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Fri, 20 Nov 2020 16:28:20 +0100 Subject: [PATCH 13/14] Interface type force selection --- luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm b/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm index 51e13edba..e044221e0 100644 --- a/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm +++ b/luci-app-openmptcprouter/luasrc/view/openmptcprouter/wizard.htm @@ -470,7 +470,7 @@
From ccb05bb3b8b98d9de2c3ea70e0becf4ec7aa5f8c Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Fri, 20 Nov 2020 16:28:46 +0100 Subject: [PATCH 14/14] Add log info for VPN restart --- mptcp/files/usr/share/omr/post-tracking.d/post-tracking | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking index 9c3c9063a..bb686c9fa 100755 --- a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking +++ b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking @@ -380,12 +380,15 @@ if [ "$OMR_TRACKER_STATUS" = "ERROR" ] || [ "$interface_up" != "true" ]; then fi fi if [ "$(uci -q get dsvpn.vpn.enable)" = "1" ]; then + _log "DSVPN down, restart it" /etc/init.d/dsvpn restart fi if [ "$(uci -q get mlvpn.general.enable)" = "1" ]; then + _log "MLVPN down, restart it" /etc/init.d/mlvpn restart fi if [ "$(uci -q get glorytun.vpn.enable)" = "1" ]; then + _log "Glorytun VPN down, restart it" /etc/init.d/glorytun restart /etc/init.d/glorytun-udp restart fi