Configuring 2nd WAN interface (Access to provider's LAN)
Posted: Sat Nov 20, 2010 5:48 am
Hello,
Does someone has experience configuring 2nd WAN interface (Access to provider's LAN), using Gargoyle/OpenWrt?
Web interface doesn't have such option.
Native firmware from TP-Link (tested WR1043ND) have such option.
I just activate (set checkmark 2nd WAN interface: Enabled) it in Web UI, enter Static IP address and Gateway.
This works with stock firmware.
Some vendors (like D-Link) call this functionality DualAccess.
But in fact this is about adding 2nd logical WAN interface to existing 1 physical WAN port.
Settings working with stock firmware:
Gargoyle Router has IP address 192.168.1.3, LAN Gateway 192.168.1.3
Internet Connection uses PPPoE.
With stock firmware and 2nd WAN interface enabled, I am connected directly to provider's LAN / gateway
With Gargoyle router, route goes via PPPoE server
With DD-Wrt running on another router, direct connection to provider's LAN was also working.
I was using following scripts:
Startup
----------------
Firewall
------------------
I would appreciate your tips what is the easiest and most efficient way to implement this in Gargoyle/OpenWrt.
Does someone has experience configuring 2nd WAN interface (Access to provider's LAN), using Gargoyle/OpenWrt?
Web interface doesn't have such option.
Native firmware from TP-Link (tested WR1043ND) have such option.
I just activate (set checkmark 2nd WAN interface: Enabled) it in Web UI, enter Static IP address and Gateway.
This works with stock firmware.
Some vendors (like D-Link) call this functionality DualAccess.
But in fact this is about adding 2nd logical WAN interface to existing 1 physical WAN port.
Settings working with stock firmware:
Code: Select all
Static IP: 10.5.72.183
Netmask: 255.255.255.0
Gateway: 10.5.72.254
Internet Connection uses PPPoE.
With stock firmware and 2nd WAN interface enabled, I am connected directly to provider's LAN / gateway
With Gargoyle router, route goes via PPPoE server
Code: Select all
>tracert 10.5.72.254
Трассировка маршрута к 10.5.72.254 с максимальным числом прыжков 30
1 <1 мс <1 мс <1 мс Gargoyle.lan [192.168.1.3]
2 1 ms <1 мс <1 мс b3-Sinichkina-11.ti.ru [212.1.254.106]
3 * * 1 ms 212.1.251.77
4 * 1 ms 1 ms 10.5.72.254
Трассировка завершена.
I was using following scripts:
Startup
----------------
Code: Select all
ifconfig vlan1 down
ifconfig vlan1 10.5.72.183 netmask 255.255.255.0
ifconfig vlan1 up
route add -net 10.0.0.0 netmask 255.0.0.0 gw 10.5.72.254
route add -net 212.1.224.0 netmask 255.255.255.0 gw 10.5.72.254
route add -net 212.1.226.0 netmask 255.255.255.0 gw 10.5.72.254
------------------
Code: Select all
iptables -A FORWARD -s 192.168.1.0/24 -j ACCEPT
iptables -A FORWARD -d 192.168.1.0/24 -j ACCEPT
iptables -t nat -A POSTROUTING -o vlan1 -s 192.168.1.0/24 -j MASQUERADE