How to configure PAT on Cisco IOS Router

I have covered the configuration of static NAT and dynamic NAT in previous lessons, now it’s time for PAT. This is the topology we’ll use:

nat 2 hosts inside outside

Let’s prepare the hosts. I am using normal Cisco routers with ip routing disabled to turn them into dumb hosts:

Host1(config)#no ip routing
Host1(config)#ip default gateway 192.168.123.3
Host2(config)#no ip routing
Host2(config)#ip default-gateway 192.168.123.3

The next step is to configure NAT:

NAT(config)#interface fastEthernet 0/0
NAT(config-if)#ip nat inside 
NAT(config)#interface fastEthernet 1/0
NAT(config-if)#ip nat outside

So far so good. Let’s create an access-list that matches both hosts:

NAT(config)#access-list 1 permit 192.168.123.0 0.0.0.255

And finally, we’ll configure PAT:

NAT(config)#ip nat inside source list 1 interface fastEthernet 1/0 overload

I select access-list 1 as my inside source, and I will translate them to the IP address on FastEthernet 1/0. The big magic keyword here is overload. If you add this, we will enable PAT!

Let’s give it a test run, shall we?

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You’ve Ever Spent on Your Cisco Career!
  • Full Access to our 798 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

547 Sign Ups in the last 30 days

satisfaction-guaranteed
100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!

Tags: , ,


Forum Replies

  1. #ip nat inside source list 1 interface fastEthernet 1/0 overload

    I do not know which interface fa1/0 meant.
    Can you please describe more specifically.

  2. N#interface fastEthernet 0/0

    Are you sure the interface is correct Sir?
    Please shed some light.
    I will take CCNA in this month.

  3. on the NAT router, there are 2 fastethernet1/0 (inside and outside)

  4. Hi Ted,

    I just changed the picture so the fastethernet interface match with the configs. It should make more sense now.

    Rene

22 more replies! Ask a question or join the discussion by visiting our Community Forum