diff --git a/luci-app-glorytun-udp/root/etc/config/glorytun-udp b/luci-app-glorytun-udp/root/etc/config/glorytun-udp index 6a526ddea..431da357a 100755 --- a/luci-app-glorytun-udp/root/etc/config/glorytun-udp +++ b/luci-app-glorytun-udp/root/etc/config/glorytun-udp @@ -8,7 +8,7 @@ config glorytun-udp 'vpn' option localip '10.255.254.2' option remoteip '10.255.254.1' option mode 'to' - option mode kxtimeout '7d' - option mode timetolerance '10m' - option mode keepalive '25s' - option mode rateauto '0' \ No newline at end of file + option kxtimeout '7d' + option timetolerance '10m' + option keepalive '25s' + option rateauto '0' \ No newline at end of file diff --git a/mptcp/files/usr/bin/multipath b/mptcp/files/usr/bin/multipath index 709be048e..896b169d2 100755 --- a/mptcp/files/usr/bin/multipath +++ b/mptcp/files/usr/bin/multipath @@ -117,21 +117,22 @@ if [ -f /proc/sys/net/mptcp/mptcp_enabled ]; then else ID=$(ip mptcp endpoint show | grep "dev $DEVICE" | awk '{print $3}') IFF=$(ip mptcp endpoint show | grep "dev $DEVICE" | awk '{print $4}') + IP=$(ifconfig $DEVICE | sed -En 's/127.0.0.1//;s/.*inet (addr:)?(([0-9]*\.){3}[0-9]*).*/\2/p') case $TYPE in "off") - [ -n "$ID" ] && ip mptcp endpoint delete id $ID + [ -n "$ID" ] && ip mptcp endpoint delete id $ID 2>&1 >/dev/null exit 0;; "on") - [ -n "$ID" ] && ip mptcp endpoint delete id $ID - ip mptcp endpoint add $IP dev $DEVICE subflow + [ -n "$ID" ] && ip mptcp endpoint delete id $ID 2>&1 >/dev/null + ip mptcp endpoint add $IP dev $DEVICE subflow fullmesh exit 0;; "signal") - [ -n "$ID" ] && ip mptcp endpoint delete id $ID - ip mptcp endpoint add $IP dev $DEVICE signal subflow + [ -n "$ID" ] && ip mptcp endpoint delete id $ID 2>&1 >/dev/null + ip mptcp endpoint add $IP dev $DEVICE signal subflow fullmesh exit 0;; "backup") - [ -n "$ID" ] && ip mptcp endpoint delete id $ID - ip mptcp endpoint add $IP dev $DEVICE backup + [ -n "$ID" ] && ip mptcp endpoint delete id $ID 2>&1 >/dev/null + ip mptcp endpoint add $IP dev $DEVICE backup fullmesh exit 0;; "") case "$IFF" in @@ -139,6 +140,7 @@ else "subflow") echo $DEVICE is in default mode;; "backup") echo $DEVICE is in backup mode;; "signal") echo $DEVICE is in signal mode;; + "fullmesh") echo $DEVICE is in fullmesh mode;; *) echo "$DEVICE Unkown state!" && exit 1;; esac exit 0;; 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 c03e5109e..13231150b 100755 --- a/mptcp/files/usr/share/omr/post-tracking.d/post-tracking +++ b/mptcp/files/usr/share/omr/post-tracking.d/post-tracking @@ -1101,7 +1101,7 @@ if [ "$multipath_config" = "on" ] || [ "$multipath_config" = "backup" ]; then 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 + if [ "$(sysctl -qn net.mptcp.mptcp_enabled | tr -d '\n')" = "1" ] || [ "$(sysctl -qn net.mptcp.enabled | tr -d '\n')" = "1" ]; then _log "Multipath $OMR_TRACKER_DEVICE switched to $multipath_config" multipath "$OMR_TRACKER_DEVICE" "$multipath_config" fi