# Cisco IOS NAT on a Stick Configuration Example

**URL:** https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062
**Category:** Lessons Discussion
**Created:** [December 26, 2016, 7:08pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062 "2016-12-26T19:08:11Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [December 26, 2016, 7:08pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/1 "2016-12-26T19:08:11Z")

</div>

This topic is to discuss the following lesson:

> **[Cisco IOS NAT on a Stick Configuration Example](https://networklessons.com/ip-services/cisco-ios-nat-stick-configuration-example)**
>
> NAT on a stick can change the source address the router uses to respond. This lesson explains how to configure this feature.

---

<div class="post-metadata">

### Author: ![system](https://cdn-forum.networklessons.com/uploads/default/original/1X/1d2ef66728c7fbac8377748594345a3f474fce5f.png) [@system](https://forum.networklessons.com/u/system)
#### Post date: [October 8, 2013, 7:39pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/2 "2013-10-08T19:39:22Z")

</div>

Hi,

Excellent article. I especially like this kind of setup because they are rare and enforce us to make our brain work harder.  
I think there’s some kind of typo in the beginning, in the basic configuration of R2. The following line seems to be missing:

```
R2(config)#interface fa0/0
R2(config-if)#no shutdown
R2(config-if)#ip address 192.168.12.2 255.255.255.0

R2(config-if)#interface loopback 0 &lt;- This one

R2(config-if)#ip address 2.2.2.2 255.255.255.0

```

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [October 23, 2013, 9:22am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/3 "2013-10-23T09:22:06Z")

</div>

Hi Steve,

Merci for letting me know, I just fixed it. I also like these kind of scenarios, it really helps to understand the way Cisco IOS processes packets and makes us think a bit more.

Rene

---

<div class="post-metadata">

### Author: ![system](https://cdn-forum.networklessons.com/uploads/default/original/1X/1d2ef66728c7fbac8377748594345a3f474fce5f.png) [@system](https://forum.networklessons.com/u/system)
#### Post date: [November 13, 2013, 12:37am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/4 "2013-11-13T00:37:43Z")

</div>

Rene, you are a great person, thank you for all

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [November 25, 2013, 2:32pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/5 "2013-11-25T14:32:41Z")

</div>

Thank you as well David

---

<div class="post-metadata">

### Author: ![klausengelmann](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/k/51bf81/32.png) [@klausengelmann](https://forum.networklessons.com/u/klausengelmann)
#### Post date: [December 28, 2013, 11:42am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/6 "2013-12-28T11:42:29Z")

</div>

Rene:

Brilliant article. Network Lessons is another great work done by you !!!

Continue this way you are great !!!

---

<div class="post-metadata">

### Author: ![system](https://cdn-forum.networklessons.com/uploads/default/original/1X/1d2ef66728c7fbac8377748594345a3f474fce5f.png) [@system](https://forum.networklessons.com/u/system)
#### Post date: [December 31, 2013, 9:18am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/7 "2013-12-31T09:18:09Z")

</div>

Dear Rene,  
Very Thankful for your Post and all of them are very good for me.  
Happy New Year !!! RENE

---

<div class="post-metadata">

### Author: ![system](https://cdn-forum.networklessons.com/uploads/default/original/1X/1d2ef66728c7fbac8377748594345a3f474fce5f.png) [@system](https://forum.networklessons.com/u/system)
#### Post date: [January 3, 2014, 5:32pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/8 "2014-01-03T17:32:59Z")

</div>

Interesting and epic work, seems to me like one of the funky CCIE scenarios…

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [January 5, 2014, 10:01pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/9 "2014-01-05T22:01:09Z")

</div>

Glad to hear you like it. It’s something I encountered during my CCIE studies.

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [January 5, 2014, 10:05pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/10 "2014-01-05T22:05:56Z")

</div>

Thanks Klaus! Glad you like it!

---

<div class="post-metadata">

### Author: ![mostafarashedi](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/m/dc4da7/32.png) [@mostafarashedi](https://forum.networklessons.com/u/mostafarashedi)
#### Post date: [September 8, 2015, 8:42pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/11 "2015-09-08T20:42:59Z")

</div>

hi rene  
i access a server That server not have GW behind a router how to config this nat ((plz describe DNAT and Full NAT in serprate article))

host-A-----------------R2-----------------SW-------Server

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [September 8, 2015, 9:34pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/12 "2015-09-08T21:34:53Z")

</div>

Hi Mostafa,

Take a look at this example:

> **[Cisco IOS NAT Port Forwarding](https://networklessons.com/cisco/ccie-routing-switching/cisco-ios-nat-port-forwarding)**
>
> This lesson explains how to configure NAT / PAT port forwarding on Cisco IOS routers.

You can use the same example if you want 1:1 NAT without specifying specific port numbers.

Rene

---

<div class="post-metadata">

### Author: ![andajose](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/a/a183cd/32.png) [@andajose](https://forum.networklessons.com/u/andajose)
#### Post date: [March 9, 2016, 3:26am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/13 "2016-03-09T03:26:39Z")

</div>

Rene,

Great article! thanks for sharing.

I am wondering if there is a real world scenario where you would need to apply Nat on a Stick, specially the second exercise…

Thanks,

Jose

---

<div class="post-metadata">

### Author: ![ReneMolenaar](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/renemolenaar/32/488_2.png) [@ReneMolenaar](https://forum.networklessons.com/u/ReneMolenaar)
#### Post date: [March 10, 2016, 9:56pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/14 "2016-03-10T21:56:31Z")

</div>

Hi Jose,

It’s unlikely to see this particular scenario…with the loopbacks, PBR and NAT it’s all a bit too much 🙂

On the ASA it is common though. Sometimes you might encounter “hairpinning” (inside-to-inside NAT). The configuration is a bit more straight-forward. Take a look at this example:

[ASA Hairpinning internal webserver](https://networklessons.com/ciscocisco-asa/cisco-asa-hairpin-internal-server/)

Rene

---

<div class="post-metadata">

### Author: ![bhargavisharma3](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/b/5f8ce5/32.png) [@bhargavisharma3](https://forum.networklessons.com/u/bhargavisharma3)
#### Post date: [September 25, 2016, 9:39pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/15 "2016-09-25T21:39:30Z")

</div>

Rene,

Great!! explanation. 🙂  
You are awesome.

---

<div class="post-metadata">

### Author: ![maher1](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/m/9dc877/32.png) [@maher1](https://forum.networklessons.com/u/maher1)
#### Post date: [September 26, 2016, 8:30am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/16 "2016-09-26T08:30:28Z")

</div>

Thanks again bhargavi for your words. You message has been forwarded to Rene.

Good learning.

---

<div class="post-metadata">

### Author: ![kayoumt](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/k/87869e/32.png) [@kayoumt](https://forum.networklessons.com/u/kayoumt)
#### Post date: [July 3, 2017, 5:40am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/17 "2017-07-03T05:40:52Z")

</div>

Very interesting ; but, I have some questions.

- Question-1

I do not see the signification of “PBR” in the lesson ?

- Question-2

In the first scenario, the answer is return back by a “Reply” arrow. But, in second and third scenarios, the answer is returned by a “NAT” arrow. What is the difference between “Reply” and “NAT” answers ?

---

<div class="post-metadata">

### Author: ![lagapidis](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/lagapidis/32/4949_2.png) [@lagapidis](https://forum.networklessons.com/u/lagapidis)
#### Post date: [July 4, 2017, 7:13am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/18 "2017-07-04T07:13:52Z")

</div>

Hello Maodo

> [@kayoutoure](#):
>
> Question-1
> 
> I do not see the signification of “PBR” in the lesson ?

If you notice after the second diagram, it states that any traceroute initiated from R1 to R2 will cause FastEthernet 0/0 to respond rather than going all the way to the loopback interface and back triggering a NAT translation. This is remedied by using PBR.

> [@kayoutoure](#):
>
> Question-2
> 
> In the first scenario, the answer is return back by a “Reply” arrow. But, in second and third scenarios, the answer is returned by a “NAT” arrow. What is the difference between “Reply” and “NAT” answers ?

The difference is that in the first case, no NAT translations take place. After PBR is implemented, NAT translations take place, packets reach the loopback interface and are returned back to R1 having already gone through a NAT translation.

I hope this has been helpful!

Laz

---

<div class="post-metadata">

### Author: ![hah2930](https://cdn-forum.networklessons.com/letter_avatar_proxy/v4/letter/h/d2c977/32.png) [@hah2930](https://forum.networklessons.com/u/hah2930)
#### Post date: [February 20, 2019, 7:45pm UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/19 "2019-02-20T19:45:35Z")

</div>

Awesome article Rene! Thanks for putting it together. How about if we switch the INSIDE and OUTSIDE NAT interfaces? and configure the NAT translation instead. That way, there won’t be a need to configure a local policy.

**Topology**  
[R1]--------------(NAT OUTSIDE) [R2] ---- loopback0 (NAT INSIDE)

**Configuration**  
`ip nat inside source list 100 interface Loopback0 overload`

**Verification**

```
 R1#traceroute 192.168.12.2 numeric
 Type escape sequence to abort.
 Tracing the route to 192.168.12.2 
 VRF info: (vrf in name/id, vrf out name/id)
 1 2.2.2.2 3 msec * 2 msec

```

---

<div class="post-metadata">

### Author: ![lagapidis](https://cdn-forum.networklessons.com/user_avatar/forum.networklessons.com/lagapidis/32/4949_2.png) [@lagapidis](https://forum.networklessons.com/u/lagapidis)
#### Post date: [February 24, 2019, 7:24am UTC](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062/20 "2019-02-24T07:24:33Z")

</div>

Hello Haseeb

Your scenario does indeed fulfill the requirement of having the loopback respond in the traceroute. Thanks for sharing that!

One of the restrictions that was mentioned in the lesson is that we require traffic to flow from the inside interface to the outside interface such that the sender of the ICMP packets is on the inside of the network.

It’s always interesting to see multiple scenarios and thanks once again for sharing!

Laz

[Next page](https://forum.networklessons.com/t/cisco-ios-nat-on-a-stick-configuration-example/1062.md?page=2)
