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

Less log for MPTCP init

This commit is contained in:
Ycarus (Yannick Chabanois) 2024-01-19 11:47:12 +01:00
parent 5bc24b9727
commit ff2f5f804f

View file

@ -406,10 +406,14 @@ interface_multipath_settings() {
fi
if [ "$(uci -q get openmptcprouter.settings.force_multipath)" != "0" ]; then
logger -t "MPTCP" "Set $iface to $mode"
if [ "$mode" = "master" ]; then
if ([ "$mode" = "master" ] || [ "$mode" = "on" ]) && [ -z "$(multipath $iface | grep default)" ]; then
logger -t "MPTCP" "Set $iface to $mode"
multipath "$iface" "on"
else
elif [ "$mode" = "off" ] && [ -z "$(multipath $iface | grep deactivated)" ]
logger -t "MPTCP" "Set $iface to $mode"
multipath "$iface" "$mode"
elif [ "$mode" = "backup" ] && [ -z "$(multipath $iface | grep backup)" ]
logger -t "MPTCP" "Set $iface to $mode"
multipath "$iface" "$mode"
fi
fi