01-24-2011 07:17 AM - edited 03-06-2019 03:09 PM
I am trying to NAT a webserver to a routable IP address. I just have the server directly plugged into my router and need to NAT its IP (172.30.194.131) to the other side of the router (172.30.180.28).
Here is the config:
interface FastEthernet0/0
ip address 172.30.180.25 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 172.30.194.135 255.255.255.192
ip nat outside
duplex auto
speed auto
!
ip route 0.0.0.0 0.0.0.0 172.30.180.1
!
no ip http server
ip nat inside source static 172.30.194.131 172.30.180.28
ip nat outside source static 172.30.194.131 172.30.180.28
That's it.
Now, my pings work fine and when I show IP NAT Translations I can see the translation table. But I cannot HTTP to the same IP address. I don't think there is anything special to do with HTTP. Any thoughts?
James
Solved! Go to Solution.
01-24-2011 07:46 AM
Hi,
access-list 20 permit WEB_SERVER_LOCAL_IP
ip nat pool websrv WEB_SERVER_PUBLIC_IP WEB_SERVER_LOCAL_IP netmask 255.255.255.252
ip nat inside source list 20 pool websrv overload
ip nat inside source static tcp WEB_SERVER_LOCAL_IP 80 WEB_SERVER_PUBLIC_IP 80
hth
Muammer
01-24-2011 07:46 AM
Hi,
access-list 20 permit WEB_SERVER_LOCAL_IP
ip nat pool websrv WEB_SERVER_PUBLIC_IP WEB_SERVER_LOCAL_IP netmask 255.255.255.252
ip nat inside source list 20 pool websrv overload
ip nat inside source static tcp WEB_SERVER_LOCAL_IP 80 WEB_SERVER_PUBLIC_IP 80
hth
Muammer
01-24-2011 08:12 AM
So you are saying I need a specific NAT for HTTP?
I will give it a shot.
James
01-25-2011 12:27 AM
Hi James,
don't need a specific NAT, you can try,
ip nat inside source static tcp WEB_SERVER_LOCAL_IP 80 WEB_SERVER_PUBLIC_IP 80
or
ip nat inside source static WEB_SERVER_LOCAL_IP WEB_SERVER_PUBLIC_IP
hth
Muammer
01-25-2011 01:47 AM
Hi James,
you can define simple nat like below to be able to connect that nated server through http (80)
ip nat inside source static tcp 10.50.50.52 80 196.27.24.79 80 extendable
Please rate if this helped you...
Regards,
Naidu.
01-25-2011 03:06 AM
It was much easier than this.
I had it right. The server team had the wrong default gateway. My NAT Translations were looking all good and everything so I couldn't figure it out until I started at the bottom and worked my way up.
Since this is a test box only on the inside corporate network I didnt need the port 80 only open.
Thanks for the help!
James
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide