Page 1 of 1
Bridge WAN IP to local device?
Posted: Tue Aug 26, 2014 11:08 am
by hendry
Hi there,
I would like a local device to have the WAN IP, but still have the other devices behind the router on a NAT.
Is that possible?
Current
122.7.219.77 -> 192.168.88.161 & 192.168.88.et al
Now I want 192.168.88.161 to basically be 122.7.219.77, but still have 192.168.88.* work.
Thanks!
Re: Bridge WAN IP to local device?
Posted: Tue Aug 26, 2014 3:21 pm
by plisken
IF you will connect the device on your WAN.
Has WAN configured a DHCP-server?
So yes
Make a bridge named br-wan
add ports the interface that now connect to the WAN
and another free ethernet interface.
Connect the device to this ethernet port.
Don't forget configured firewall NAT all what have configured as WAN must change to interface br-lan
Sorry for my bad englisch but i try to help you
Re: Bridge WAN IP to local device?
Posted: Tue Aug 26, 2014 5:52 pm
by hendry
IF you will connect the device on your WAN.
Has WAN configured a DHCP-server?
Not it's bridge-local IIUC
http://s.natalian.org/2014-08-26/140906 ... 64x748.png
add ports the interface that now connect to the WAN
and another free ethernet interface.
Connect the device to this ethernet port.
I can tell you it's on ether3...
http://s.natalian.org/2014-08-26/140906 ... 64x748.png
Maybe I should just forward all ports somehow to 192.168.88.133 instead. But I keep hearing "NAT is bad" hence I wanted this situation.
Re: Bridge WAN IP to local device?
Posted: Tue Aug 26, 2014 6:16 pm
by Kickoleg
if understand right you need netmap ?
try to use this :
ip firewall nat add chain=dstnat dst-address=122.7.219.77 action=netmap to-address=192.168.88.133
Re: Bridge WAN IP to local device?
Posted: Tue Aug 26, 2014 6:29 pm
by hendry
ip firewall nat add chain=dstnat dst-address=122.7.219.77 action=netmap to-address=192.168.88.133
Perfect!!
That works. But what happens if my WAN IP changes? 122.7.219.77 could change to 122.7.219.78 (this IIUC is my vlan1 address). Depends on my ISP's whim.
Re: Bridge WAN IP to local device?
Posted: Tue Sep 16, 2014 12:53 pm
by MadEngineer