思科路由实现内⽹访问Internet静态NAT内⽹访问Internet静态NAT1、 实验⽬标在路由器上配置NAT2 、试验要求需要在CPE路由器上配置NAT。内⽹PC0 10.1.1.1访问Internet源地址⽤172.16.1.2.10公⽹地址替换。其他内⽹的计算机不能访问Internet。3 、试验拓扑4 、实验过程:4.1 在路由器PCE上Router>enRouter#confi tRouter(config)#ip nat inside source static 10.1.1.1 172.16.12.10指定对应关系Router(config)#interface fastEthernet 0/1Router(config-if)#ip nat inside 指定NAT的内⽹接⼝Router(config-if)#exitRouter(config)#interface s0/0Router(config-if)#ip nat outside 指定NAT的外⽹接⼝Router#5 、验证5.1 在PC0上访问Server2的Web站点可以发现PC0能够访问Webserver2。5.2 在PC1上Ping Server25.3 在Server2上查看会话表明内⽹的计算机访问Server2的Web站点时,源地址使⽤公⽹地址172.16.12.10替换了。5.4 在路由器CPE上Router#show ip nat translationsRouter#debug ip nat 可以看到NAT转换IP NAT debugging is onRouter#
NAT: s=10.1.1.1->172.16.12.10, d=172.16.23.2[0]NAT*: s=172.16.23.2, d=172.16.12.10->10.1.1.1[0]NAT: s=10.1.1.1->172.16.12.10, d=172.16.23.2[0]NAT: s=10.1.1.1->172.16.12.10, d=172.16.23.2[0]NAT*: s=172.16.23.2, d=172.16.12.10->10.1.1.1[0]NAT*: s=172.16.23.2, d=172.16.12.10->10.1.1.1[0]NAT: s=10.1.1.1->172.16.12.10, d=172.16.23.2[0]NAT: s=10.1.1.1->172.16.12.10, d=172.16.23.2[0]NAT*: s=172.16.23.2, d=172.16.12.10->10.1.1.1[0]NAT*: s=172.16.23.2, d=172.16.12.10->10.1.1.1[0]