Accessing a DSL Modem Behind a PPPoE Router
Often the standard combined DSL modem / router provided by the ISP has only basic functionalities or lacks performance for many parallel connections.
It is advisable to use this simple DSL modem / router as modem only and use a more powerful and feature rich router for PPPoE, NAT and routing.
This simple modem only mode is often called “bridge mode”. There are a couple of good routers running Linux which allow to install feature rich 3rd party SW. Namely the Linksys WRT54GL is widely used and very well supported.
--------- PPPoE ------ DSL_line ========= DSL_modem ========= Router ========== LAN --------- ------
This configuration has the disadvantage that we do not have any control over the DSL modem anymore. The routers WAN side does not have any IP address as PPPoE runs directly on Ethernet.
The modem itself has usually still an IP address, but there is no routing from the internal LAN to the router’s WAN side.
To be able to check, e.g. the line quality or do some configurations on the DSL modem, we would to disconnect the router and connect the terminal directly to the modem, or make the modem-WAN port part of the LAN, e.g. looping over a LAN connected switch, maybe the routers LAN ports.
A better solution would be to assign an IP address to the routers WAN port and add routing towards this port. For this configuration, the modem IP address must be of a different network than the LAN.
In my case the default modem IP is 192.168.1.1/24 while my LAN uses 192.168.0.0/24.
My router is a WRT54GL and runs the alternative tomato firmware.
Assign an IP address out the modem’s network:
ip addr add 192.168.1.2/24 dev vlan1 brd +
Modify IPTABLES to allow the traffic towards WAN port:
iptables -I POSTROUTING -t nat -o vlan1 -d 192.168.1.0/24 -j MASQUERADE
Those two lines can be added as startup script under Administration-Scripts-Firewall.
Thanks to:
http://www.dslreports.com/forum/r22626720-How-to-Access-Modem-via-Tomato-Router