mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
map-agent: hotplug: map-dynamic-backhaul: remove tracking of port connections prior to dynbh start
This commit is contained in:
parent
67ee062946
commit
9a5564bca4
1 changed files with 0 additions and 25 deletions
|
|
@ -1,6 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
conn_ports_file="/var/run/multiap/map.connected.ports"
|
||||
map_bh_file="/var/run/multiap/multiap.backhaul"
|
||||
|
||||
# Exit if AL Bridge is not configured to be a bridge device
|
||||
|
|
@ -30,30 +29,6 @@ al_brnet="${al_bridge:3}"
|
|||
|
||||
############## Dynamic Backhaul Daemon ##############
|
||||
if [ -n "$(which dynbhd)" ]; then
|
||||
pidof dynbhd >/dev/null && exit 0 # dynbhd is managing the links
|
||||
|
||||
if [ ! -f $conn_ports_file ]; then
|
||||
mkdir -p /var/run/multiap
|
||||
touch $conn_ports_file
|
||||
if [ "$LINK" = "up" ]; then
|
||||
touch $conn_ports_file
|
||||
echo "$PORT" > $conn_ports_file
|
||||
brctl delif $al_bridge $PORT
|
||||
#ubus call network.interface.lan remove_device "{\"name\":\"$PORT\"}"
|
||||
fi
|
||||
else
|
||||
if [ "$LINK" = "up" ]; then
|
||||
brctl delif $al_bridge $PORT
|
||||
echo "$PORT" >> $conn_ports_file
|
||||
#ubus call network.interface.lan remove_device "{\"name\":\"$PORT\"}"
|
||||
else
|
||||
sed -i -E "/(^|:)${PORT}(:|$)/d" $conn_ports_file
|
||||
#ubus call network.interface.lan add_device "{\"name\":\"$PORT\"}"
|
||||
brctl addif $al_bridge $PORT
|
||||
[ "$(cat $conn_ports_file | wc -c)" = "0" ] && rm -f $conn_ports_file
|
||||
fi
|
||||
fi
|
||||
|
||||
exit 0
|
||||
fi
|
||||
########################################################
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue