Assuming your modem's IP address is 192.168.100.1 and it is connected to the router's WAN interface.
modem@wan192.168.100.2255.255.255.0wanMake sure the modem subnet doesn't overlap with your LAN, otherwise change the LAN subnet.
lan interface and change the IP address:192.168.2.1At this point the modem should be reachable from any host in the LAN.
If you are using the BanIP package, make sure to add the IP to the allowlist. Ex. 192.168.100.0/24
Assuming your modem's IP address is 192.168.100.1 and it is connected to the router's WAN interface.
Set up a static WAN alias and assign it to the WAN zone.
# Configure network uci -q del network.modem uci set network.modem="interface" uci set network.modem.proto="static" uci set network.modem.device="@wan" uci set network.modem.ipaddr="192.168.100.2" uci set network.modem.netmask="255.255.255.0" uci commit network service network restart # Configure firewall uci del_list firewall.@zone[1].network="modem" uci add_list firewall.@zone[1].network="modem" uci commit firewall service firewall restart
Make sure the modem subnet doesn't overlap with your LAN, otherwise change the LAN subnet.
# Configure network uci set network.lan.ipaddr="192.168.2.1" uci commit network service network restart
If the WAN L2 device doesn't match L3 device like in case of PPPoE, change the modem interface.
# Fetch WAN L2 device . /lib/functions/network.sh network_flush_cache network_find_wan NET_IF network_get_physdev NET_L2D "${NET_IF}" # Configure network uci set network.modem.device="${NET_L2D}" uci commit network service network restart