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

Fix metrics on imported backup

This commit is contained in:
Ycarus (Yannick Chabanois) 2024-03-13 20:38:23 +01:00
parent b83c9b985f
commit 2d3eac400f

View file

@ -79,6 +79,18 @@ config_load network
#config_foreach _setup_macvlan_update interface
config_foreach _setup_mptcp_handover_to_on interface
_fix_metrics() {
uci -q batch <<-EOF
delete openmptcprouter.$1.metric
delete network.$1.metric
commit openmptcprouter
commit network
EOF
}
config_load openmptcprouter
config_foreach _fix_metrics interface
if [ "$(uci -q show network.lan | grep multipath)" != "" ]; then
exit 0
fi