How to bridge an ISP modem to my td-w8980?

Hi, all! I have a TD-W8980 device running openwrt as a modem/router combo. I want to bridge my ISP modem to it and use it as a router only.

I've turned off all routering functions on my ISP device (DHCP, Firewall, etc.) and set it to bridge mode, but I've some questions regarding OpenWrt configs...

  1. How to turn one of the switch LAN ports into a WAN port so I can hook up the modem?

  2. Should I config my ISP credentials on Openwrt or on the modem?

  3. Since TD-W8980 was working as a modem/router combo, are there any network interfaces or firewall configs that need to be adjusted in order to bridge the modem properly?

  1. Add VLAN 2 as wan on LAN4 on the Network/Switch page, or whatever port you wish to use.
    On the Network/Interfaces/WAN/Physical page, set the Interface to eth0.2
  2. On the Network/Firewall Zone Settings page, add wan zone and set it to
    lan to wan: accept, accept, accept
    wan to lan: reject, accept, reject, masqueraded
  3. Change wan protocol to pppoe and enter credentials on Openwrt wan-pppoe page.

I have a BT HH5A with a red WAN port on the back of the unit. The red WAN port can input pppoe with an external bridged modem, or share the vdsl line with OpenWrt.

1 Like

Thanks for replying!

Excuse my ignorance, I can't really follow you here, I believe I'm supposed to press the 'Add VLAN' button on the switch page, which creates another instance but the last LAN port is still labeled as LAN 4, how exactly should I config it as a WAN port?

Click "Add VLAN". There is now another row labeled 2, which is the VLAN number. In that row set the CPU port to tagged and the LAN 4 port to untagged. In row 1 set the LAN 4 port to off.

eth0.2 is now linked to the LAN 4 port. eth0.1 remains with the other three LAN ports.

In the WAN physical settings, change the interface from the internal modem (dsl0) to eth0.2, which now leads to your external modem. If the modem is fully bridged and the pppoe was set up to use your subscription with the internal modem, no other changes should be needed.

2 Likes

Thank you, guys and sorry for the long silence! that was very instructive, however, I didn't manage to get it to work. The modem 'Internet led' is dead, probably I missed configured it, or worst it doesn't support true bridge mode, I think I need to discuss this with my ISP custom services.

Just so I can eliminate Openwrt out of the problem, may you please revise my configs?

Network Config

config interface 'loopback'
	option ifname 'lo'
	option proto 'static'
	option ipaddr '127.0.0.1'
	option netmask '255.0.0.0'

config globals 'globals'
	option ula_prefix 'fd44:cc68:ab0d::/48'

config atm-bridge 'atm'
	option encaps 'llc'
	option payload 'bridged'
	option nameprefix 'dsl'
	option vci '35'
	option vpi '0'

config dsl 'dsl'
	option xfer_mode 'ptm'
	option line_mode 'vdsl'
	option ds_snr_offset '0'
	option firmware '/lib/firmware/vr9-B-dsl.FB7490-7.21.bin'
	option annex 'b'

config interface 'lan'
	option type 'bridge'
	option ifname 'eth0.1'
	option proto 'static'
	option netmask '255.255.255.0'
	option ip6assign '60'
	option ipaddr '192.168.1.1'
	option delegate '0'
	option force_link '0'
	list dns '1.1.1.1'
	list dns '1.0.0.1'
	option mtu '1492'

config interface 'wan'
	option proto 'pppoe'
	option password '12345'
	option ipv6 '0'
	option delegate '0'
	option username '12345@tedata.net.eg'
	list dns '1.1.1.1'
	list dns '1.0.0.1'
	option peerdns '0'
	option mtu '1492'
	option ifname 'eth0.2'

config device 'wan_dsl0_dev'
	option name 'dsl0'
	option macaddr 'e8:de:27:86:be:41'

config switch
	option name 'switch0'
	option reset '1'
	option enable_vlan '1'

config switch_vlan
	option device 'switch0'
	option vlan '1'
	option vid '1'
	option ports '5 6t'

config switch_vlan
	option device 'switch0'
	option vlan '2'
	option ports '4 6t'
	option vid '2'

By the way, does true/full bridge mode have any advantage over psudo bridge mode?

You can remove "atm_bridge" and "dsl" sections since those relate to the internal modem that you're not using. Or leave them it doesn't matter.

OpenWrt doesn't control the LEDs on an external modem. A full bridge is supposed to be dumb-- it doesn't generate or analyze any traffic, so it wouldn't know or care if there's any particular path to the Internet.

Oh my bad! My ISP device is actually a modem/router combo so it has an internet led, I just thought that it should be on by setting up the bridge properly, I guess the DSL led should be on on the modem, and on the router, it should be the internet led, am I getting it right?

The SmartRG SR501 modem/router Internet led turns on in bridged mode. Maybe it needs a good VPI/VCI connection to turn the Internet led on.

Ah, it looks so problematic on the modem side but I hope my ISP would be able to help. On that SmartRG model, do you connect it in a full bridge mode? do you enter your credentials on the modem or the router?

Anyway, thank you guys for your help, at least we've managed to work out the OpenWRT related stuff.

TekSavvy ships the SR501 preconfigured as a bridged modem. The credentials get entered into the router.