Configuring PAT: Many Private to One Public Address Translation


Private addresses all use a single public IP address and numerous port numbers for translation.

Step 1: Define a static route on the remote router stating where public addresses should be routed.

ISP(config)#ip route 64.64.64.64 255.255.255.255.128 s0/0

Informs the ISP where to send packets with addresses destined for 64.64.64.64 255.255.255.128

Step 2: Define a pool of usable public IP addresses on your router that will perform NAT (optional).

 

Use this step if you have many private addresses to translate. A single public IP address can handle thousands of private addresses. Without using a pool of addresses, you can translate all private addresses into the IP address of the exit inter-facethe serial link to the ISP, for example

Corp(config)#ip nat pool scott 64.64.64.70 64.64.64.70 netmask 255.255.255.128

Defines the following:

  • Name of pool is scott (The name of the pool can be anything.)

  • Start of pool is 64.64.64.70

  • End of pool is 64.64.64.70

  • Subnet mask is 255.255.255.128

Step 3: Create an ACL that will identify which private IP addresses will be translated.

Corp(config)#access-list 1 permit 172.16.10.0 0.0.0.255

 

Step 4 (Option 1): Link the ACL to the outside public interface. (Create the translation.)

Corp(config)#ip nat inside source list 1 interface serial 0/0 overload

The source of the private addresses is from ACL 1

The public address to be translated into is the one assigned to Serial 0/0

The overload keyword states that port numbers will be used to handle many translations

Step 4 (Option 2): Link the ACL to the pool of addresses. (Create the translation.)

 

If using the pool created in Step 1

Corp(config)#ip nat inside source list 1 pool scott overload

The source of the private addresses is from ACL 1

The pool of available addresses is named scott

The overload keyword states that port numbers will be used to handle many translations

Step 5: Define which interfaces are inside (con-tain the private addresses).

Corp(config)#int fa 0/0

 

Corp(config-if)#ip nat inside

You can have more than one inside interface on a router

Step 6: Define the outside interface (the interface leading to the public network).

Corp(config)#int s 0/0

 

Corp(config-if)#ip nat outside

Defines which interface is the outside interface for NAT translation


Note:

You can have an ip nat pool of more than one address, if needed. The syntax for this is Corp(config)#ip nat pool scott 64.64.64.70 74.64.64.128 netmask 255.255.255.128. You would then have a pool of 63 addresses (and all of their ports) available for translation.





CCNA Self-Study(c) CCNA Portable Command Guide
CCNA Portable Command Guide
ISBN: 1587201585
EAN: 2147483647
Year: 2006
Pages: 261
Authors: Scott Empson

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net