IP通信实验报告——NAT实验2.docx

上传人:鲁** 文档编号:548159909 上传时间:2023-06-03 格式:DOCX 页数:6 大小:12.51KB
返回 下载 相关 举报
IP通信实验报告——NAT实验2.docx_第1页
第1页 / 共6页
IP通信实验报告——NAT实验2.docx_第2页
第2页 / 共6页
IP通信实验报告——NAT实验2.docx_第3页
第3页 / 共6页
IP通信实验报告——NAT实验2.docx_第4页
第4页 / 共6页
IP通信实验报告——NAT实验2.docx_第5页
第5页 / 共6页
点击查看更多>>
资源描述

《IP通信实验报告——NAT实验2.docx》由会员分享,可在线阅读,更多相关《IP通信实验报告——NAT实验2.docx(6页珍藏版)》请在金锄头文库上搜索。

1、IP通信实验报告NAT实验2 IP 通信基础实验报告 e NAT outside to inside 实验 一、 实验目的 1、 掌握 NAT 的数据配置方法; 2、 理解和巩固 NAT 的基本原理; 二、 实验内容(仿真程序 NAT_ out side to in side.pkt ) 一台 路由器和通过二层交换机与服务器相连,作为内网,通过配置,映射成外网地址,达到互连的目的。 三、 实验设备 路由器 2 台 PC 机 1 台 交叉网线 2 条 直通网线 2 条 二层交换机 1 台 服务器 1 台 四、 实验拓扑图 五、 配置步骤 先必须配置主机 B A, B 的 的 P IP 地址; =

2、 底层配置 RT1 Continue with configuration dialog? yes/no: no Press RETURN to get started! Routerenable Router#conf t Router(config)#hostname RT1 Enter configuration commands, one per line. End with CNTL/Z. RT1(config)#interface fastEthernet 0/0 RT1(config- - if)#no shutdown %LINK- -5 5- - CHANGED: Inter

3、face FastEthernet0/0, changed state to up %LINEPROTO- -5 5- - UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up RT1(config- - if)#ip address 12.1 2.12.254 255.255.255.0 RT1(config- - if)#exit RT1(config)#interface fastEthernet 1/0 RT1(config- - if)#no shutdown RT1(config- - if)

4、#ip address 23.23.23.1 255.255.255.0 RT1(config- - if)#exit RT1(config)# RT2= = = Continue with configuration dialog? yes/no: no Press RETURN to get started! Routerenable Router#conf t Enter configuration commands, one per line. End with CNTL/Z. Router(config)#hostname RT2 RT2(config)#interface fast

5、Ethernet 1/0 RT2(config- -i i f)#no shutdown %LINK- -5 5- - CHANGED: Interface FastEthernet1/0, changed state to up %LINEPROTO- -5 5- - UPDOWN: Line protocol on Interface FastEthernet1/0, changed state to up RT2(config- - if)#ip address 23.23.23.2 255.255.255.0 RT2(config- - if)#exit RT2(config)#int

6、erf ace fastEthernet 0/0 RT2(config- - if)#no shutdown %LINK- -5 5- - CHANGED: Interface FastEthernet0/0, changed state to up %LINEPROTO- -5 5- - UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up RT2(config- - if)#ip address 192.168.10.254 255.255.255.0 R R T2(config- - if)#exi

7、t RT2(config)# = 配置静态路由 RT1 RT1(config)#ip route 192.168.10.0 255.255.255.0 23.23.23.2 / 注意,这一条指令不需要,因为外网看不到内网 RT2 RT2(config)#ip route 12.12.12.0 255.255.255.0 23.23.23.1 = 配置 NAT RT2 RT2(config)#interface fastEthernet 0/0= 指明该端口是对内的端口 RT2(config- - if)#ip nat insi de RT2(config- - if)#exit RT2(con

8、fig)#interface fastEthernet 1/0= 指明该端口是对外的端口 RT2(config- - if)#ip nat outside RT2(config- - if)#exit RT2(config)#ip nat inside source static 192.168.10.1 23.23.23.3= 配置端口映射,指明外界对 3 23.23.23.3 的访问被静态的转换到内网 1 192.168.10.1 上 六、 验证方法及验证结果 1. 此时 ,可在 2 RT2 全局模式下使用 show ip nat translations 查看 T NAT 结果,如下 图上部分 : 2. 用主机 1 PC1 去 去 g ping 服务器 P IP 地址 23.23.23.3 ,再使用 do show ip nat translations 查看 T NAT 结果,如下 图下部分: 所示:

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 商业/管理/HR > 其它文档 > 租房合同

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号