S0
S0
S1
S1
Loopback 1
DCE
DCE
R1
R2
R3
R1:
no ip routing(不做路由协议了,可以把R1看成是一台电脑)
interface Serial0
ip address
ip default-gateway
R2:
interface Serial0
ip address
ip nat inside(定义内部端口)
clockrate 64000
interface Serial1
ip address
ip nat outside(定义外部端口)
clockrate 64000
ip nat pool ABC (告诉路由器外网地址范围)
access-list 1 permit (告诉路由器内网地址范围)
ip nat inside source list 1 pool ABC overload(将内网地址和外网地址做转换)(注意:“overload”,其转换方式是复用动态地址转换)
ip route (做默认路由指向外网)
R3:
interface Loopback1
ip address
interface Serial1
ip address
R1#ping
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to , timeout is 2 seconds:
!!!!!
ess rate is 100 percent (5/5), round-trip
CCNA实验之NAT 来自淘豆网m.daumloan.com转载请标明出处.