原版CCNA教材19章NATppt课件.ppt

上传人:sccc 文档编号:5554446 上传时间:2023-07-20 格式:PPT 页数:20 大小:860.04KB
返回 下载 相关 举报
原版CCNA教材19章NATppt课件.ppt_第1页
第1页 / 共20页
原版CCNA教材19章NATppt课件.ppt_第2页
第2页 / 共20页
原版CCNA教材19章NATppt课件.ppt_第3页
第3页 / 共20页
原版CCNA教材19章NATppt课件.ppt_第4页
第4页 / 共20页
原版CCNA教材19章NATppt课件.ppt_第5页
第5页 / 共20页
点击查看更多>>
资源描述

《原版CCNA教材19章NATppt课件.ppt》由会员分享,可在线阅读,更多相关《原版CCNA教材19章NATppt课件.ppt(20页珍藏版)》请在三一办公上搜索。

1、第十九章网络地址翻译 NAT,NAT网络地址翻译,随着Internet的飞速发展,网上丰富的资源产生着巨大的吸引力接入Internet成为当今信息业最为迫切的需求但这受到IP地址的许多限制首先,许多局域网在未联入Internet之前,就已经运行许多年了,局 域网上有了许多现成的资源和应用程序,但它的IP地址分配不符合 Internet的国际标准,因而需要重新分配局域网的IP地址,这无疑是 劳神费时的工作其二,随着Internet的膨胀式发展,其可用的IP地址越来越少,要想 在ISP处申请一个新的IP地址已不是很容易的事了,NAT(网络地址翻译)能解决不少令人头疼的问题它解决问题的办法是:在内部

2、网络中使用内部地址,通过NAT把内部地址翻译成合法的IP地址,在Internet上使用其具体的做法是把IP包内的地址池(内部本地)用合法的IP地址段(内部全局)来替换,Chapter Activities,Windows 95 PC,Modem,Branch office,ISDN/analog,Small office,Central site,Frame Relay,PRI,BRI,BRI,Frame Relay,Async,AAA server,Async,SA10.1.1.1,166.1.1.1,SA,Inside Local,IP Address,10.1.1.1,Inside Gl

3、obal IP,Address,166.1.1.1,NAT table,PAT,NAT 术语NAT 功能NAT 三种类型,NAT 术语,Internet,Inside,10.1.1.1,Inside Local IP,Address,10.1.1.1,Simple NAT table,Inside Global,IP Address,166.1.1.1,10.1.1.2,Host B,172.20.7.3,A,C,B,A,B,D,SA10.1.1.1,DA10.1.1.1,SA166.1.1.1,DA166.1.1.1,D,C,内部本地地址:私有IP,不能直接用于互连网。内部全局地址:用来代替

4、内部本地IP地址的,对外,或在互联网上是合法的的IP地址。,NAT 功能,Inside Local,IP Address,10.1.1.1,10.1.1.2,NAT table,Inside Global,IP Address,196.168.2.2,196.168.2.3,NAT 功能:内部网络地址转换复用内部的全局地址TCP 负载均衡解决网络地址重叠,Internet,Inside,10.1.1.1,10.1.1.2,复用内部的全局地址,将一个内部全局地址用于同时代表多个内部局部地址。主要用IP地址和端口号的组合来唯一区分各个内部主机。目前在公司内普遍应用。,复用内部的全局地址,10.1.

5、1.2:1723,10.1.1.1:1024,NAT table,196.168.2.2:1723,196.168.2.2:1024,TCP,TCP,10.1.1.3:1492,196.168.2.2:1492,TCP,Internet,Inside,10.1.1.1,Host B,179.20.7.3,1,3,SA10.1.1.1,DA10.1.1.1,SA196.168.2.2,DA196.168.2.2,10.1.1.2,10.1.1.3,4,5,2,Host C,179.21.7.3,DA196.168.2.2,4,Inside Global IP,Address:Port,Proto

6、col,Inside Local IP,Address:Port,10.1.1.1,NAT三种类型,NAT有三种类型:静态NAT(staticNAT)、NAT池(pooledNAT)和端口NAT(PAT)。其中静态NAT设置起来最为简单,内部网络中的每个主机都被永久映 射成 外部网络中的某个合法的地址,多用于服务器。而NAT池则是在外部网络中定义了一系列的合法地址,采用动态分配 的方法映射到内部网络,多用于网络中的工作站。PAT则是把内部地址映射到外部网络的一个IP地址的不同端口上。,NAT静态映射实例,interface Ethernet0ip address 172.16.1.1 255.

7、255.255.0ip nat inside(指定内部接口)!interface Serial0 ip address 200.1.1.1 255.255.255.0 ip nat outside(指定外部接口)!ip nat inside source static 172.16.1.3 200.1.1.1(建立两个IP地址之间的静态映射)ip classlessip route 0.0.0.0 0.0.0.0 200.1.1.2,注意:从外网到内网建立静态映射后,外网能PING通内部全局地址(200.1.1.1),如果使用真实地址,则访问失败,这是因为从外网没有到达内网的路由存在!Ping

8、 172.16.1.3 Ping 200.1.1.5!,ip nat pool dyn-nat 192.16.2.1 192.16.2.254 netmask 255.255.255.0ip nat inside source list 1 pool dyn-nat!interface Ethernet0 ip address 10.1.1.1 255.255.255.0 ip nat inside!interface Serial0 ip address 192.16.2.1 255.255.255.0 ip nat outside!access-list 1 permit 10.1.1.0

9、 0.0.0.255!,动态NAT的配置,Translate between inside hosts addressed from 10.1.1.0/24 to the globally unique 192.16.2.0/24 network.,This interface connected to the outside world.,This interface connected to the inside network.,PAT的配置,ip nat pool ovrld-nat 192.16.2.1 192.16.2.2netmask 255.255.255.0ip nat in

10、side source list 1 pool ovrld-nat overload!interface Ethernet0/0 ip address 10.1.1.1 255.255.255.0 ip nat inside!interface Serial0/0 ip address 192.16.2.1 255.255.255.0 ip nat outside!access-list 1 permit 10.1.1.0 0.0.0.255,Router#sh ip nat transPro Inside global Inside local Outside local Outside g

11、lobaltcp 192.2.2.1:11003 10.1.1.1:11003 172.16.2.2:23 172.16.2.2:23tcp 192.2.2.1:1067 10.1.1.2:1067 172.16.2.3:23 172.16.2.3:23,Verifying NAT,A translation for a Telnet is still active.Two different inside hosts appear on the outside with a single IP address.,Basic IP address translation,Unique TCP

12、port numbers are used to distinguishbetween hosts.,Router#show ip nat transProInside globalInside localOutside local Outside global-192.2.2.110.1.1.1-192.2.2.210.1.1.2-,IP address translation with overloading,Router#debug ip natNAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 0NAT*:s=172.166.2.2,d=192.16.2.1

13、-10.1.1.1 0NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 1NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 2NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 3NAT*:s=172.166.2.2,d=192.16.2.1-10.1.1.1 1NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 4NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 5NAT:s=10.1.1.1-192.16.2.1,d=172.166.2.2 6N

14、AT*:s=172.166.2.2,d=192.16.2.1-10.1.1.1 2,Troubleshooting NAT,An example address translation inside-to-outside.,A reply to the packet sent.,An example TCP conversation,inside-to-outside.,*Indicates translation was in the fast path.,Clearing NAT Translation Entries,All entries are cleared.,192.16.2.2

15、 is cleared.,Router#sh ip nat transPro Inside global Inside local Outside local Outside globaltcp 192.16.2.1:11003 10.1.1.1:11003 172.16.2.2:23 172.16.2.2:23tcp 192.16.2.1:1067 10.1.1.2:1067 172.16.2.3:23 172.16.2.3:23router#clear ip nat trans*router#router#show ip nat trans,router#show ip nat trans

16、Pro Inside global Inside local Outside localOutside globaludp 192.16.2.2:1220 10.1.1.2:1120 171.69.2.132:53 171.69.2.132:53 tcp 192.16.2.1:11003 10.1.1.1:11003 172.16.2.2:23 172.16.2.2:23tcp 192.16.2.1:1067 10.1.1.1:1067 172.16.2.3:23 172.16.2.3:23router#clear ip nat trans udp inside 192.16.2.2 10.1

17、.1.2 1220171.69.2.132 53 171.69.2.132 53 router#show ip nat transPro Inside global Inside local Outside localOutside globaltcp 192.16.2.1:11003 10.1.1.1:11003 172.16.2.2:23 172.16.2.2:23tcp 192.16.2.1:1067 10.1.1.3:1067 172.16.2.3:23 172.16.2.3:23,TCP 负载均衡,TCP 负载均衡:用于将一台虚拟的主机映射到几台真实的主机上。(如下图),TCP 负载

18、均衡,NAT table,Inside Global IP,Address:Port,10.1.1.127:80,10.1.1.127:80,10.1.1.127:80,Protocol,TCP,TCP,TCP,Inside Local IP,Address:Port,10.1.1.1:80,10.1.1.2:80,10.1.1.3:80,Internet,Inside,10.1.1.1,Host B,176.20.7.3,4,5,SA10.1.1.1,DA10.1.1.1,SA10.1.1.127,DA10.1.1.127,10.1.1.2,10.1.1.1,1,3,2,Host C,176.21.7.3,10.1.1.127,10.1.1.3,Virtualhost,Realhosts,

展开阅读全文
相关资源
猜你喜欢
相关搜索
资源标签

当前位置:首页 > 建筑/施工/环境 > 农业报告


备案号:宁ICP备20000045号-2

经营许可证:宁B2-20210002

宁公网安备 64010402000987号