I'm trying to avoid a double NAT, and offload as much processing to
the RT-N16 (so bridging the WAN and LAN isn't an option)
the simple thing would be to set the DSL-502T to PPPoE but My ISP
doesn't support PPPoE so I'm stuck with PPPoA.
I'm actually trying to do the same. I've got the D-Link G604T (AR7,
which works fine for terminating PPPoA and doing the routing) but I
want my new TP-Link WR-1043ND to do all the heavy lifting.

If you can write the right scripts and sockets... I wonder if
  the following is possible... a sort of hacky PPPoE without PPPoE ;-).


Consider routers "ar7" and "power-router".

Configure the lan-ip on "ar7" as 192.168.5.1/24
configure the wan-ip on "power-router" as 192.168.5.2/24

On the ar7...  change the PPP configuration so that pppd does not
  configure the IP address or routing on the wan interface, just
  set up the connection and note the IP address offered.

On ar7...
* Figure-out how to get a script to run on ppp-up and ppp-down.
* Setup ppp-up script to:-
    "ip route add default dev ppp0"
    "ip route add $WAN_IP via 192.168.5.2"
    And, put the WAN_IP into a file in the web-root.
* Setup ppp-down script to undo the above...


On power-router...
* Configure 192.168.5.2/24 as the IP on the WAN
    with NO GATEWAY/route.

* Setup a script that polls the first router for
    its' reported wan_ip address....
  * Upon receiving the WAN_IP, it should then:-
      "ip addr add $WAN_IP dev eth0"
      "ip route add default via 192.168.5.1 src $WAN_IP"
      (and, locally make note of this IP)
  * Open losing the WAN_IP, it should remove the above,
      using the previous WAN_IP ...


The "src" (source-hint) tells linux what IP to use as the
  ''source'' on MASQUERADE rules and when choosing a
  source-ip on a socket connecting outbound....

I've had something like that working before between a
  linux nat box and a wan-router, but due to details
  of the ARP/firewall implementation in that router,
  it was necessary to leave a ping going between the
  192.168.5.2 and 192.168.5.1 .....

--Simon
_______________________________________________
openwrt-users mailing list
[email protected]
https://lists.openwrt.org/mailman/listinfo/openwrt-users

Reply via email to