路由与交换技术

上传人:hs****ma 文档编号:513649046 上传时间:2023-07-22 格式:DOCX 页数:11 大小:125.07KB
返回 下载 相关 举报
路由与交换技术_第1页
第1页 / 共11页
路由与交换技术_第2页
第2页 / 共11页
路由与交换技术_第3页
第3页 / 共11页
路由与交换技术_第4页
第4页 / 共11页
路由与交换技术_第5页
第5页 / 共11页
点击查看更多>>
资源描述

《路由与交换技术》由会员分享,可在线阅读,更多相关《路由与交换技术(11页珍藏版)》请在金锄头文库上搜索。

1、路由与交换技术实验报告课 程 名 称路 由 与 交 换实验名称将PC转化为路由器分组名单教师审批2015 年 6 月一. 实验名称基于quagga及linux,将PC转换为路由器。二实验要求利用两台交换机完成其之间的RIP及OSPF路由。三实验环境Linux系统,quagga软件二. 实验目的实现两台虚拟机之间的RIP及OSPF路由,掌握路由器相关知识,熟悉配 置操作,提高动手能力,加深课程体会。三. 实验内容及步骤、结果 为了熟悉软件操作及使用,在完成这个实现几个要求的综合网络拓扑前,我对 几个要求分别进行了实验。小实验 1:配置 zebra小实验 2:配置 ripd小实验 3:配置 osp

2、fd综合实验:使用虚拟机进行RIP和OSPF路由 实验原理:虚拟机间路由定义为使用路由器从一个虚拟机向另一个虚拟机 转 发网络流量的过程。虚拟机与网络中唯一的 IP 地址相关联。这种配置为实现 多网段环境中的路由过程提供了依据。通过路由器进行 虚拟机间路由时,路 由器接口可连接到不同的网段。网络拓扑设计:1、配置 Zebra1)启动 zebra 进程,设置 hostname 为 Router,以及 ethO 的 ip address 为 192.168.1.2/24, eth0:0 的 ip address 为 192.168.4.1/24Router(conftg)# interface e

3、thoRouter(config-if)# ip address 192.168.1*2/24 Router(匚onfig-ifno shutdownRouter(config-if)# exitRouter(conftg)# interface ethO:Router(匚onfig-ifip address 192*168.4*1/24 Router(config-if)# no shutdownRouter(conftg-if)# exitsudo password for alpha:rootalpha-Lenovo-IdeaPad-Y47Q:-/文档/quagga-0.99.11# z

4、ebra -drootgalpha-Lenovo-IdeaPad-Y470:-/文档/quagga-0.99.11# telnet localhost 2601 Trying 127.0.0.1.Connected to localhost.Escape character is *A1Hello, this is Quagga (version 0.99.11).Copyright 1996-2005 Kunihiro Ishiguro, et alUser Access VerificationPassword:Router enablePassword:Router# config tR

5、outer(config)# interface ethoRouter(config-if)# ip address 192.168.2.1/24Router(configif)# no shutdownRouter(config-if)# endRouter# show running config% ZEBRA Unknown comma nd: show runni. ng con fig Router# show runningCurrent configuration:ihostname Routerpassword zebraenable password zebraiinterf

6、ace ethoip address 192168.2.1/24 ipv6 nd suppress-raiinterface loIinterface wlanOipv6 nd suppress-ra2) 用show running-config查看运行配置3) 用 show interface description查看端口状态:4) 将运行配置保存到startup-config中2、配置 RIP1)启动ripd,进入ripd进程,并修改名称,ripd的进程号是2602,于是我们可以使用命 令 telnet localhost 2602 进入 Router 的 ripd 设置,登陆口令默认是

7、 zebra2)启动rip协议,并指定哪个网络使用rip协议rootalpha- Lenovo - IdeaPad-Y470:/Xif/qudggd-0*99.11# telnet localhost 2602 Trying 127*0*0.1* *Connmt亡d to localhost.Escape character is A1 *Hello, this is Quagga (version 0*99*11)*Copyright 1996-2005 Kunihiro Ishtguro, et al*User Access VerificationPassword:ripd enripd

8、# conf t192.168,1.0/24192.168.4.6/24ripd(conftg)# router rip ripd(config-router)# network ripd(config-router)# network ripd(conftg-router)# end ripd# show runC查看已运行配田置,并并厂&七行行配:亠Fripd(config-router)# network 192*168*3.0/24 ripd(config-router)# endripd# show unCurrent configuration:hostname ripdpassw

9、ord zebralog stdout!router ripnetwork 192,168.3,0/24line vtyendripd# show ip ripCodes: R - RIP, C - connect亡d, S - Static, 0 - OSPF, B - BGP Subcodes:(n) - norndlf (s) - static (d) - default, (r) - redistribute, wii - ip查看甘Networkri nrl斗Next HopMetric FromTag Time*u I uuLdipiid-i-nuvu-iuvidriGiu-T n

10、t u;i iipd(config-router)# network 192.168,3*0/24 ipd(config-router)# endtpd# show unCurrent configuration:lostname ripd jassword zebra.og stdoutouter ripnetwork 192*168.3*0/24.ine vty?ndipd# show ip rip50)通过-RgP查看-由器之间的通-状况tic, 0 - OSPF, B - BGP通过-g 一看口由器之间的通I 口状儿(n) - normal, (s) - static, (d) - d

11、efault, (r) - redistribute, (i) - interfaceNetworkNext HopMetric FromTag TimelandLink encap:网 硬件地址 e0:94:67:18:le:lainettnet6 t也址:fe80:e294:67ff :fel8:lela/64 Scope: Link UP BROADCAST RUNNING MULTICAST MTU: 1509 乐点数:1 接收数据包:2881错误同丢弃同过载沖帧数浦 发送数据包:3544错误沖丢弃沖过载沖载波沖 碰撞沖发送队列长度:1000接收字节:428164 (428*1 KB)

12、 发送字节:253070 (253.0 KB)地址:10,42.0.10 广播:10*42疋.255 掩码:255.255.255.0rootgalpha-Lenovo-IdeaPad-Y476 rootgalpha-Lenovo-IdeaPad-470 rootgalpha-Lenovo-IdeaPad-Y476 rootgalpha-Lenovo-IdeaPad-470 rootgalpha-Lenovo-IdeaPad-Y476 rootgalpha-Lenovo-IdeaPad-470 rootgalpha-Lenovo-IdeaPad-Y476 rootgalpha-Lenovo-I

13、deaPad-470 rootgalpha-Lenovo-IdeaPad-Y476 ootalphm-Lenovo-Idea卩ad-4了3# # K K # # K Kifconfig ifconftg ifconfig ifconfig ifconfig ifconftg ifconfig ifconfig ifconfigethO 192,168,1.2 eth0:0 192.168,4.1ethO 192,168,1.2eth0:0 192*168,4,1ethO 192,168,1.2eth0:0 192.168,4.1eth0:0 192*163,4,1ethO 192,168,1.

14、2eth0:0 192*168,4,13、配置 ospfd1)启动ospfd,进入ospfd进程,并修改名称,ospfd的进程号是2604,于是我们可以使 用命令telnet localhost 2604进入Router的ospfd设置,登陆口令默认是zebraalphdalpha- Lenovo-IdeaPad-470:-/文裆/quagga-0占9:L$ sudo -ssudo password for alpha:rootgalpha- Lenovo- IdeaPdd-470:/文档/quagga-0.99.11# ospfd -d rootgalpha- Lenovo- IdeaPad

15、Y470:/文档/quagga-0.99.11# telnet localhost 26( Trying 127*0,0*1,匸onnetted to localhost*Esc ape 匚 haracis 1 A | *Hello, this is Quagga (version 0*99*11)*Copyright 1996-2005 Kunihiro Ishiguro, et al.User Access HirificationPassword: ospfd enospfd# conf t192*168,1*0/24 area 0192.168,4.0/24 area 0ospfd(config)# router ospf ospfd(匚onfig-outer)# network ospfd(config- router)# network ospfd(config-router)# end ospfd# show ip ospfO

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

当前位置:首页 > 学术论文 > 其它学术论文

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