计网实验报告3.docx

上传人:b****7 文档编号:9146000 上传时间:2023-02-03 格式:DOCX 页数:19 大小:63.11KB
下载 相关 举报
计网实验报告3.docx_第1页
第1页 / 共19页
计网实验报告3.docx_第2页
第2页 / 共19页
计网实验报告3.docx_第3页
第3页 / 共19页
计网实验报告3.docx_第4页
第4页 / 共19页
计网实验报告3.docx_第5页
第5页 / 共19页
点击查看更多>>
下载资源
资源描述

计网实验报告3.docx

《计网实验报告3.docx》由会员分享,可在线阅读,更多相关《计网实验报告3.docx(19页珍藏版)》请在冰豆网上搜索。

计网实验报告3.docx

计网实验报告3

四川大学计算机学院、软件学院

实验报告

学号:

__姓名:

专业:

计算机科学与技术班级:

第周

课程名称

计算机网络 

实验课时

4

实验项目

RIPv2配置

WEB服务器配置实验

实验时间

2015.11.18

2015.11.25

实验目的

理解RIP两个版本之间的区别,掌握如何配置RIPv2

实验环境

路由器

实验内容(算法、程序、步骤和方法)

RIPv2配置

需求分析

两台路由器通过快速以太网端口连接在一起,每个路由器上设置2个Loopback端口模拟子网,在所有端口运行RIP路由协议,实现所有子网间的互通。

实验原理

RIP协议有两个版本RIPv1和RIPv2。

RIPv1属于有类路由协议,不支持VLSM(变长子网掩码),RIPv1是以广播的形式进行路由信息的更新的;更新周期为30秒。

RIPv2属于无类路由协议,支持VLSM(变长子网掩码),RIPv2是以组播的形式进行路由信息的更新的,组播地址是224.0.0.9。

RIPv2还支持基于端口的认证,提高网络的安全性。

实验步骤

第一步:

配置两台路由器的主机名、接口IP地址

Ruijie>enable

Ruijie#configureterminal

Enterconfigurationcommands,oneperline.EndwithCNTL/Z.

Ruijie(config)#hostnameRouterA

RouterA(config)#

RouterA(config)#interfacefastEthernet0/0

RouterA(config-if-FastEthernet0/0)#ipaddress192.168.1.1255.255.255.0

RouterA(config-if-FastEthernet0/0)#noshutdown

RouterA(config-if-FastEthernet0/0)#exit

RouterA(config)#

RouterA(config)#interfaceloopback0

RouterA(config-if-Loopback0)#*Nov1814:

19:

41:

%LINK-3-UPDOWN:

InterfaceLoopback0,changedstatetoup.

*Nov1814:

19:

41:

%LINEPROTO-5-UPDOWN:

LineprotocolonInterfaceLoopback0,changedstatetoup.

RouterA(config-if-Loopback0)#ipaddress172.16.1.1255.255.255.0

RouterA(config-if-Loopback0)#exit

RouterA(config)#

RouterA(config)#interfaceloopback1

RouterA(config-if-Loopback1)#*Nov1814:

20:

27:

%LINK-3-UPDOWN:

InterfaceLoopback1,changedstatetoup.

*Nov1814:

20:

27:

%LINEPROTO-5-UPDOWN:

LineprotocolonInterfaceLoopback1,changedstatetoup.

RouterA(config-if-Loopback1)#ipaddress172.16.2.1255.255.255.0

RouterA(config-if-Loopback1)#exit

MJY(config)#

MJY(config)#interfacefastEthernet0/0

MJY(config-if-FastEthernet0/0)#ipaddress192.168.1.2255.255.255.0

MJY(config-if-FastEthernet0/0)#noshutdown

MJY(config-if-FastEthernet0/0)#exit

MJY(config)#

MJY(config)#interfaceloopback0

MJY(config-if-Loopback0)#*Nov1814:

17:

05:

%LINK-3-UPDOWN:

InterfaceLoopback0,changedstatetoup.

*Nov1814:

17:

05:

%LINEPROTO-5-UPDOWN:

LineprotocolonInterfaceLoopback0,changedstatetoup.

MJY(config-if-Loopback0)#ipaddress10.1.1.1255.255.255.0

MJY(config-if-Loopback0)#exit

MJY(config)#

MJY(config)#interfaceloopback1

MJY(config-if-Loopback1)#*Nov1814:

17:

53:

%LINK-3-UPDOWN:

InterfaceLoopback1,changedstatetoup.

*Nov1814:

17:

53:

%LINEPROTO-5-UPDOWN:

LineprotocolonInterfaceLoopback1,changedstatetoup.

MJY(config-if-Loopback1)#ipaddress10.2.2.1255.255.255.0

MJY(config-if-Loopback1)#exit

第二步:

在两台路由器上启用RIPv2,但不关闭自动汇总

RouterA(config)#routerrip

RouterA(config-router)#network192.168.1.0

RouterA(config-router)#network172.16.1.0

RouterA(config-router)#version2

RouterA(config-router)#exit

MJY(config)#routerrip

MJY(config-router)#network192.168.1.0

MJY(config-router)#network10.0.0.0

MJY(config-router)#version2

MJY(config-router)#exit

第三步:

查看路由表

RouterA(config)#showiproute

Codes:

C-connected,S-static,R-RIP,B-BGP

O-OSPF,IA-OSPFinterarea

N1-OSPFNSSAexternaltype1,N2-OSPFNSSAexternaltype2

E1-OSPFexternaltype1,E2-OSPFexternaltype2

i-IS-IS,su-IS-ISsummary,L1-IS-ISlevel-1,L2-IS-ISlevel-2

ia-IS-ISinterarea,*-candidatedefault

Gatewayoflastresortisnoset

R10.0.0.0/8[120/1]via192.168.1.2,00:

00:

30,FastEthernet0/0

C172.16.1.0/24isdirectlyconnected,Loopback0

C172.16.1.1/32islocalhost.

C172.16.2.0/24isdirectlyconnected,Loopback1

C172.16.2.1/32islocalhost.

C192.168.1.0/24isdirectlyconnected,FastEthernet0/0

C192.168.1.1/32islocalhost.

MJY(config)#showiproute

Codes:

C-connected,S-static,R-RIP,B-BGP

O-OSPF,IA-OSPFinterarea

N1-OSPFNSSAexternaltype1,N2-OSPFNSSAexternaltype2

E1-OSPFexternaltype1,E2-OSPFexternaltype2

i-IS-IS,su-IS-ISsummary,L1-IS-ISlevel-1,L2-IS-ISlevel-2

ia-IS-ISinterarea,*-candidatedefault

Gatewayoflastresortisnoset

C10.1.1.0/24isdirectlyconnected,Loopback0

C10.1.1.1/32islocalhost.

C10.2.2.0/24isdirectlyconnected,Loopback1

C10.2.2.1/32islocalhost.

R172.16.0.0/16[120/1]via192.168.1.1,00:

00:

07,FastEthernet0/0

C192.168.1.0/24isdirectlyconnected,FastEthernet0/0

C192.168.1.2/32islocalhost.

第四步:

关闭自动路由汇总

RouterA(config)#routerrip

RouterA(config-router)#noauto-summary

RouterA(config-router)#end

RouterA#*Nov1814:

22:

48:

%SYS-5-CONFIG_I:

Configuredfromconsolebyconsole

MJY(config)#routerrip

MJY(config-router)#noauto-summary

MJY(config-router)#end

MJY#*Nov1814:

20:

19:

%SYS-5-CONFIG_I:

Configuredfromconsolebyconsole

第五步:

查看RIP配置信息,路由表

RouterA#showiproute

Codes:

C-connected,S-static,R-RIP,B-BGP

O-OSPF,IA-OSPFinterarea

N1-OSPFNSSAexternaltype1,N2-OSPFNSSAexternaltype2

E1-OSPFexternaltype1,E2-OSPFexternaltype2

i-IS-IS,su-IS-ISsummary,L1-IS-ISlevel-1,L2-IS-ISlevel-2

ia-IS-ISinterarea,*-candidatedefault

Gatewayoflastresortisnoset

R10.0.0.0/8[120/1]via192.168.1.2,00:

01:

20,FastEthernet0/0

C172.16.1.0/24isdirectlyconnected,Loopback0

C172.16.1.1/32islocalhost.

C172.16.2.0/24isdirectlyconnected,Loopback1

C172.16.2.1/32islocalhost.

C192.168.1.0/24isdirectlyconnected,FastEthernet0/0

C192.168.1.1/32islocalhost.

可以看到RIP路由表中已经学习到了子网的路由

RouterA#showiprip

RoutingProtocolis"rip"

Sendingupdatesevery30seconds,nextduein22seconds

Invalidafter180seconds,flushedafter120seconds

Outgoingupdatefilterlistforallinterfaceis:

notset

Incomingupdatefilterlistforallinterfaceis:

notset

Redistributiondefaultmetricis1

Redistributing:

Defaultversioncontrol:

sendversion2,receiveversion2

InterfaceSendRecv

FastEthernet0/022

Loopback022

Loopback122

RoutingforNetworks:

172.16.0.0255.255.0.0

192.168.1.0255.255.255.0

Distance:

(defaultis120)

在配置RIPv2版本后,RIP路由器将只接收和发送版本2的更新报文

RouterA#showipripdatabase

10.0.0.0/8auto-summary

10.0.0.0/8

[1]via192.168.1.2FastEthernet0/000:

40

10.1.1.0/24

[1]via192.168.1.2FastEthernet0/000:

10

10.2.2.0/24

[1]via192.168.1.2FastEthernet0/000:

10

172.16.0.0/16auto-summary

172.16.1.0/24

[1]directlyconnected,Loopback0

172.16.2.0/24

[1]directlyconnected,Loopback1

192.168.1.0/24auto-summary

192.168.1.0/24

[1]directlyconnected,FastEthernet0/0

RouterA#showipripinterface

FastEthernet0/0isup,lineprotocolisup

RoutingProtocol:

RIP

ReceiveRIPv2packetsonly

SendRIPv2packetsonly

ReceiveRIPpacket:

Enabled

SendRIPpacket:

Enabled

SendRIPsupernetroutes:

Enabled

Passiveinterface:

Disabled

Splithorizon:

Enabled

BFD:

Disabled

V2Broadcast:

Disabled

Multicastregister:

Registed

InterfaceSummaryRip:

NotConfigured

Authenticationmode:

TEXT

IPinterfaceaddress:

192.168.1.1/24

Loopback0isup,lineprotocolisup

RoutingProtocol:

RIP

ReceiveRIPv2packetsonly

SendRIPv2packetsonly

ReceiveRIPpacket:

Enabled

SendRIPpacket:

Enabled

SendRIPsupernetroutes:

Enabled

Passiveinterface:

Disabled

Splithorizon:

Enabled

BFD:

Disabled

V2Broadcast:

Disabled

Multicastregister:

Registed

InterfaceSummaryRip:

NotConfigured

Authenticationmode:

TEXT

IPinterfaceaddress:

172.16.1.1/24

Loopback1isup,lineprotocolisup

RoutingProtocol:

RIP

ReceiveRIPv2packetsonly

SendRIPv2packetsonly

ReceiveRIPpacket:

Enabled

SendRIPpacket:

Enabled

SendRIPsupernetroutes:

Enabled

Passiveinterface:

Disabled

Splithorizon:

Enabled

BFD:

Disabled

V2Broadcast:

Disabled

Multicastregister:

Registed

InterfaceSummaryRip:

NotConfigured

Authenticationmode:

TEXT

IPinterfaceaddress:

172.16.2.1/24

MJY#showiproute

Codes:

C-connected,S-static,R-RIP,B-BGP

O-OSPF,IA-OSPFinterarea

N1-OSPFNSSAexternaltype1,N2-OSPFNSSAexternaltype2

E1-OSPFexternaltype1,E2-OSPFexternaltype2

i-IS-IS,su-IS-ISsummary,L1-IS-ISlevel-1,L2-IS-ISlevel-2

ia-IS-ISinterarea,*-candidatedefault

Gatewayoflastresortisnoset

C10.1.1.0/24isdirectlyconnected,Loopback0

C10.1.1.1/32islocalhost.

C10.2.2.0/24isdirectlyconnected,Loopback1

C10.2.2.1/32islocalhost.

R172.16.0.0/16[120/1]via192.168.1.1,00:

01:

24,FastEthernet0/0

R172.16.1.0/24[120/1]via192.168.1.1,00:

00:

24,FastEthernet0/0

R172.16.2.0/24[120/1]via192.168.1.1,00:

00:

24,FastEthernet0/0

C192.168.1.0/24isdirectlyconnected,FastEthernet0/0

C192.168.1.2/32islocalhost.

MJY#showiprip

RoutingProtocolis"rip"

Sendingupdatesevery30seconds,nextduein30seconds

Invalidafter180seconds,flushedafter120seconds

Outgoingupdatefilterlistforallinterfaceis:

notset

Incomingupdatefilterlistforallinterfaceis:

notset

Redistributiondefaultmetricis1

Redistributing:

Defaultversioncontrol:

sendversion2,receiveversion2

InterfaceSendRecv

FastEthernet0/022

Loopback022

Loopback122

RoutingforNetworks:

10.0.0.0255.0.0.0

192.168.1.0255.255.255.0

Distance:

(defaultis120)

MJY#

MJY#showipripdat

10.0.0.0/8auto-summary

10.1.1.0/24

[1]directlyconnected,Loopback0

10.2.2.0/24

[1]directlyconnected,Loopback1

172.16.0.0/16auto-summary

172.16.0.0/16

[1]via192.168.1.1FastEthernet0/001:

20

172.16.1.0/24

[1]via192.168.1.1FastEthernet0/000:

20

172.16.2.0/24

[1]via192.168.1.1FastEthernet0/000:

20

192.168.1.0/24auto-summary

192.168.1.0/24

[1]directlyconnected,FastEthernet0/0

MJY#showipripdatabase

10.0.0.0/8auto-summary

10.1.1.0/24

[1]directlyconnected,Loopback0

10.2.2.0/24

[1]directlyconnected,Loopback1

172.16.0.0/16auto-summary

172.16.0.0/16

[1]vi

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

当前位置:首页 > 高等教育 > 农学

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1