Configuration Guide Configuring NAT
A(config-if-GigabitEthernet 0/0)# ip nat inside
A(config-if-GigabitEthernet 0/0)# exit
A(config)# interface GigabitEthernet 0/1
A(config-if-GigabitEthernet 0/1)# ip address 200.198.12.1 255.255.255.0
A(config-if-GigabitEthernet 0/1)# ip nat outside
A(config-if-GigabitEthernet 0/1)# exit
A(config)# ip nat pool net200 200.168.12.1 200.168.12.1 netmask 255.255.255.0
A(config)# ip nat inside source list 1 pool net200
A(config)# access-list 1 permit 192.168.12.0 0.0.0.255
A(config)# ip nat inside source static tcp 192.168.12.3 80 200.198.12.1 80
Use the show command to display the configuration.
Ruijie# show ip nat translations
Pro Inside global Inside local Outside local Outside global
tcp 200.168.12.200:2063 192.168.12.65:2063 168.168.12.1:23 168.168.12.1:23
icmp 200.168.12.200:2064 192.168.12.66:2063 168.168.12.1:23 168.168.12.1:23
udp 200.168.12.200:2065 192.168.12.67:2063 168.168.12.1:23 168.168.12.1:23
tcp 200.168.12.200:2066 192.168.12.68:2063 168.168.12.1:23 168.168.12.1:23
tcp 200.168.12.200:2067 192.168.12.69:2063 168.168.12.1:23 168.168.12.1:23
Common Errors
The inside or outside interface is not configured.
The ACL configuration is incorrect.
10.4.3 Configuring Overlapping NAT
Networking
Requirements
When the same IP address is allocated to two private networks to interconnect with each other or the same global IP
address is allocated to a private network and a public network, this situation is called address overlapping. Two
overlapping network hosts cannot communicate, because both hosts consider that the peer host is in the local network.
Overlapping NAT is especially designed to implement the communications between two networks with the same IP
address. After overlapping NAT is configured, an extranet host address will be represented as another host address in the
intranet, and vice versa.
Notes
Internal source address translation must be configured before overlapping NAT is configured.
The newly configured NAT rules take effect on new flows only but not on any existing flows.
Configuration Steps
Configuring the NAT Inside Interface
Mandatory configuration.