Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

To do NAT for source and destination at the same time on Router

Hi Guys,

I am manage to do translation for destination IP using ip nat inside source static 10.8.1.1 172.16.1.1 but how can i do it for source ip as well??

I need to achieve something like below:

PC A (121.x.x.x) will be translated to an NAT IP before accessing 172.16.1.1 web apps tat will also translate to 10.8.1.1 (the real web server IP)..

How I do this with a router?

TIA!

cindy

2 REPLIES
Bronze

Re: To do NAT for source and destination at the same time on Rou

Cindy

the statement : ip nat inside static 10.8.1.1 172.16.1.1 make your web server apearing to the outside network as if it has an address 172.16.1.1, to make it operational you have to add at the interface of the router connected to your server/(or switch) (ip nat inside) and at the interface connected to the outside network (ip nat outside).

for the PC that has an address for instance 121.x.x.x

do the following :

access-list 1 permit host 121.x.x.x

ip nat pool test 172.17.1.0 172.17.1.254 prefix-length 24

ip nat inside source list 1 pool test

at the interface connected to your PC : ip nat inside.

at the interface connected to your outside network : ip nat outside

(your server will be reachable from the outside using 172.16.1.1 and not 10.8.1.1)

(your pc will appear to the web sevrver as if it has an ip address from the pool 172.17.1.x, the first one available)

and the pool of addresses you can choose anyone

HTH

please do rate if does clarify

Community Member

Re: To do NAT for source and destination at the same time on Rou

Thanks Kamal,

Will try and let you guys know about the answer ya..:D

Thanks again..

cindy

132
Views
0
Helpful
2
Replies
CreatePlease to create content