IP路由协议的配置实例
- 格式:doc
- 大小:49.00 KB
- 文档页数:6
二、RIP协议配置1.实验内容:在H3C路由器上配置RIP协议2.实验目的:掌握RIP协议的配置3.实验环境:4.实验步骤此时再测试网络在静态路由实验基础上,删除静态路由的配置之后再启动RIP协议,其配置命令和配置信息以及路由表信息如下:[RTA]undo ip route-static 202.0.1.0 255.255.255.0 192.0.0.2[RTA]rip[RTA-rip]network all[RTB]undo ip route-static 202.0.0.0 255.255.255.0 192.0.0.1[RTB]rip[RTB-rip]network all查看RTA的配置信息和路由表,路由表显示如下:[RTA)display ip routing-tableRoutingTables:Destination/Mask Proto Pref Metric Nexthop Interface127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBackO127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0192.0.0.1/0/24 Direct 0 0 192.0.0.2Serial0192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0192.0.0.2/32 Direct 0 0 192.0.0.2Serial0202.0.0.1/0/24 Direct 0 0 202.0.0.1 Ethernet0202.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0202.0.1.1/0/24 RIP 100 1 192.0.0.2Serial0RTB路由器上的配置和RTA的配置相似。
查看RTB的路由表信息如下:[RTB]display ip routing-tableRoutingTables:Destination/Mask Proto Pref Metric Nexthop Interface127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0192.0.0.1/0/24 Direct 0 0 192.0.0.1 SerialO192.0.0.1/32 Direct 0 0 192.0.0.1 SerialO192.0.0.2/32 Direct 0 0 127.0.0.1 LoopBack0202.0.0.1/0/24 RIP 100 1 192.0.0.1 Serial0202.0.1.1/0/24 Direct 0 0 202.0.1.1 Ethernet0202.0.1.1/32 Direct 0 0 127.0.0.1 LoopBack0测试网络互通性,应该是全网互通的。
静态路由配置案例。
路由器A配置:[routeA]interf ace e0[routeA-e0]ip addres s 192.168.0.1 255.255.255.0[routeA]interf ace s0[routeA-s0]ip addres s 192.168.1.1 255.255.255.0[routeA-s0]link-protoc ol ppp [配置封装协议][routeA]ip route-static192.168.3.0 255.255.255.0 192.168.1.2 prefer ence60 [设置静态路由,优先级为60]路由器B配置:[routeB]interf ace e0[routeB-e0]ip addres s 192.168.3.1 255.255.255.0[routeB]interf ace s0[routeB-s0]ip addres s 192.168.2.1 255.255.255.0[routeA-s0]link-protoc ol ppp [配置封装协议][routeA]ip route-static 192.168.0.0 255.255.255.0 192.168.1.1 prefer ence60 [设置静态路由,优先级为60]使用默认路由配置:缺省路由也是一种静态路由.简单地说,缺省路由就是在没有找到任保匹配置的路由项情况下,才使用的路由.即只有当无任何合适的路由时,缺省路由才被使用.[rotueA]ip route-statci 0.0.0.0 0.0.0.0 s0 prefer ence60『注意』上面命令中用到了Ser ial 0,接口的名字,如串口封装P P P 或HD LC协议,这时可以不用指定下一跳地址,只需指定发送接口即可。
实验4.3 RIP 协议基本配置*【实验目的】•理解RIP 的基本配置【实验过程】假设在校园网在地理上分为 2 个区域,每个区域内分别有一台路由器连接了 2 个子网,需要将两台路由器通过以太网链路连接在一起并进行适当的配置,以实现这 4 个子网之间的互联互通。
两台路由器通过快速以太网端口连接在一起,每个路由器上设置 2 个 Loopback 端口模拟子网,在所有端口运行 RIP 路由协议,实现所有子网间的互通。
实验拓扑:实验编地址见表2-4。
名称 IP 地址 子网掩码 默认网关 端口 R1(2901) 192.168.1.1 255.255.255.0 N/A Gig0/0 172.16.1.1 255.255.255.0 N/A Loopback0172.16.2.1 255.255.255.0 N/A Loopback1 R2(2901) 192.168.1.2 255.255.255.0 N/A Gig0/0 10.1.1.1 255.255.255.0 N/A Loopback010.1.2.1255.255.255.0N/ALoopback1注: R1指路由器名称,2901指路由器型号;Gig0是GigabitEthernet0的缩写,/0指第0号端口; Loopback 指Loopback 端口1基本配置根据实验编址进行相应的配置,其中Loopback 配置方法类似一般的端口配置。
基本配置完成后,使用ping 命令检测路由器R1和R2直连链路的连通性。
实例:配置Loopback 端口R1#conf t~进入全局配置模式Gig0/0Loopback 0R1R2 Gig0/0Loopback 0Loopback 1Loopback 1Enter configuration commands, one per line. End with CNTL/Z.R1(config)#int Loopback0~进入端口配置模式R1(config-if)#ip address 172.16.1.1 255.255.255.0 ~配置端口IP地址,掩码R1(config-if)#no shutdown~开启该端口(非常重要!)%LINK-5-CHANGED: Interface Loopback0, changed state to upR1(config-if)#end~结束配置%SYS-5-CONFIG_I: Configured from console by consoleR1#show int loopback0~查看端口状态Loopback0 is up, line protocol is up (connected)Hardware is LoopbackInternet address is 172.16.1.1/24 ~显示IP地址配置正确•••R1#Loopback是路由器软件虚拟的端口,是逻辑上的一个端口,它没有物理的存在。
SX6000配置实例本书是介绍SX6000的应用时配置实例,在实现以下应用前,基础数据需要预先配置。
且本书配置实例中将应用福州和厦门的SX6000的设备进行举例。
介绍实例所使用的“创建”,意指使用人员可登录SX6000页面,通过操作“新建”相关配置,或“编辑”已有配置,才创建了所需要的数据。
本实例使用“用户”,表示连接到到SX6000下各终端用户。
实例中介绍配置步骤时,未指出配置项则保留默认值。
在创建用户前,需按以下步骤配置所需的基础数据:1. 协议参数配置1)RTP参数配置:RTP中转口“WAN口”,RTP加密“不加密”。
2. 本局数据配置1)创建国家/地区码配置福州和厦门的设备均为:全局号首集“0”,国家/地区码“86”,国家/地区名“china”。
2)创建国内长途区号配置福州SX6000设备下,全局号首集“0”,国家/地区码“86”,国内长途区号“591”,城市名“Fuzhou”,行政区“FZ”。
厦门SX6000设备下,全局号首集“0”,国家/地区码“86”,国内长途区号“592”,城市名“Xiam”,行政区“XM”。
3)创建全局长途字冠福州和厦门的设备均为:全局号首集“0”,国家/地区码“86”,国家内长途字冠“0”,国际长途字冠“00”。
4)创建本地号道集配置福州SX6000设备下,本地号首集“0”,全局号首集“0”,国家/地区码为“86”,国内长途区号“591”,本地号首名称“福州”,MGCP DigtMap为空。
厦门SX6000设备下,本地号首集“0”,全局号首集“0”,国家/地区码为“86”,国内长途区号“592”,本地号首名称“福州”,MGCP DigtMap为空。
(该项配置在第2、3章中用到)5)创建呼叫源配置:呼叫源码“0”,呼叫源名称“0”,预收号码位数“1”,本地号首集“0”,路由选择源码“0”,失败源码“0”,号码准备“否”,主叫地址甄别“不甄别”,其它选项均为默认参数。
华为路由器dhcp简单配置实例session 1 DHCP的工作原理DHCP(Dynamic Host Configuration Protocol,动态主机配置协议)是一个局域网的网络协议,使用UDP协议工作,主要有两个用途:给内部网络或网络服务供应商自动分配IP地址,给用户或者内部网络管理员作为对所有计算机作中央管理的手段,在RFC 2131中有详细的描述。
DHCP有3个端口,其中UDP67和UDP68为正常的DHCP 服务端口,分别作为DHCP Server和DHCP Client的服务端口;546号端口用于DHCPv6 Client,而不用于DHCPv4,是为DHCP failover服务,这是需要特别开启的服务,DHCP failover是用来做“双机热备”的。
DHCP协议采用UDP作为传输协议,主机发送请求消息到DHCP服务器的67号端口,DHCP服务器回应应答消息给主机的68号端口,DHCP的IP地址自动获取工作原理及详细步骤如下:1、DHCP Client以广播的方式发出DHCP Discover报文。
2、所有的DHCP Server都能够接收到DHCP Client发送的DHCP Discover报文,所有的DHCP Server都会给出响应,向DHCP Client发送一个DHCP Offer报文。
DHCP Offer报文中“Your(Client) IP Address”字段就是DHCP Server 能够提供给DHCP Client使用的IP地址,且DHCP Server会将自己的IP地址放在“option”字段中以便DHCP Client 区分不同的DHCP Server。
DHCP Server在发出此报文后会存在一个已分配IP地址的纪录。
3、DHCP Client只能处理其中的一个DHCP Offer报文,一般的原则是DHCP Client处理最先收到的DHCP Offer报文。
通过在外网口配置nat基本就OK 了,以下配置假设EthernetO/O为局域网接口,EthernetO/1 为外网口。
1、配置内网接口( EthernetO/O):[MSR20-20 ] in terface EthernetO/O[MSR20-20 - EthernetO/O]ip add 192.168.1.1 242、使用动态分配地址的方式为局域网中的PC分配地址[MSR20-20 ]dhcp server ip-pool 1[MSR20-20 -dhcp-pool-1]network 192.168.1.0 24[MSR20-20 -dhcp-pool-1]dns-list 202.96.134.133[MSR20-20 -dhcp-pool-1] gateway-list 192.168.1.13、配置nat[MSR20-20 ]nat address-group 1 公网IP 公网IP[MSR20-20 ]acl number 3000[MSR20-20 -acl-adv-3000]rule 0 permit ip4、配置外网接口( EthernetO/1)[MSR20-20 ] in terface EthernetO/1[MSR20-20 - Ethernet0/1]ip add 公网IP[MSR20-20 - EthernetO/1] nat outbound 3000 address-group 15 .加默缺省路由[MSR20-20 ]route-stac 0.0.0.0 0.0.0.0 夕卜网网关总结:在2020路由器下面,配置外网口,配置内网口,配置acl作nat,一条默认路由指向电信网关.ok!Console登陆认证功能的配置关键词:MSR;co nsole;一、组网需求:要求用户从con sole登录时输入已配置的用户名h3c和对应的口令h3c,用户名和口令正确才能登录成功。
目录1静态路由 ············································································································································ 1-11.1 静态路由简介····································································································································· 1-11.2 配置静态路由····································································································································· 1-11.2.1 配置准备 ································································································································· 1-11.2.2 配置静态路由 ·························································································································· 1-11.3 配置静态路由与BFD联动 ·················································································································· 1-21.3.1 双向检测 ································································································································· 1-21.3.2 单跳检测 ································································································································· 1-31.4 配置静态路由快速重路由功能 ··········································································································· 1-31.5 静态路由显示和维护·························································································································· 1-41.6 静态路由典型配置举例 ······················································································································ 1-51.6.1 静态路由基本功能配置举例 ···································································································· 1-51.6.2 配置静态路由与BFD联动(直连) ························································································· 1-71.6.3 配置静态路由与BFD联动(非直连)······················································································ 1-81.6.4 静态路由快速重路由配置举例······························································································· 1-10 2缺省路由 ············································································································································ 2-12.1 缺省路由简介····································································································································· 2-11 静态路由1.1 静态路由简介静态路由是一种特殊的路由,由管理员手工配置。
RIP1.rip——路由信息协议,是一种距离向量协议。
2.度量基于跳数,最长15跳,16跳为不可达。
3.路由更新为每隔30s一次的广播更新,180s后未确认的为失效,240s后仍未确认的则删除路由信息。
4.路由环路:距离向量类的算法容易产生环路,解决方法:1.水平分割;记住路由来源,不在收到信息的端口上再次发送。
2.触发更新;突破30s规则,发生路由变化时立即发送更新信息,减少环路可能性。
3.毒性逆转;路径无效后,标记为16广播出去,而不立即删除。
4.逆制计时;减少路由浮动,增加了稳定性。
5.两个版本的异处:1.V2支持非连续子网和VLSM,V1则不支持。
2.V2支持认证,增加了系统的可靠性和安全性,V1不支持。
3.V2采用组播方式发送更新,V1使用广播。
注:由于V2向下兼容V1,所以默认V1在所有接口上发送V1版本的路由信息,在所以接口上接受V1和V2版本的数据包,在V2接口上只发送和接受V2版本的数据包。
也可在V2上用命令:ip send rip version 和ip send rip revcived version 命令来同时发送和更新两个版本的路由信息。
关于时钟的问题:cisco设备现在都是自动开启的。
但使用模拟器做实验需在DCE端口手动开启时钟。
命令:clock rate <参数>实例:1. 拓扑结构:2.ip地址分配如图,均为192.168.X.X网段。
3.具体配置[在R2上配置]:Router(config)#router ripRouter(config-router)#net 192.168.1.0Router(config-router)#net 192.168.2.0Router(config-router)#end/注:首先启用路由协议,在宣告直连网段,很简单,依次在每个路由上配置。
测试:在R2上show ip route 得到下面结果:C 192.168.1.0/24 is directly connected, Serial1/1C 192.168.2.0/24 is directly connected, Serial1/0R 192.168.3.0/24 [120/1] via 192.168.2.2, 00:00:02, Serial1/0 最后一条即学到的路由信息,配置成功。
华为路由器配置实例华为路由器配置实例1.硬件连接配置1.1 连接路由器①将电缆连接到路由器的WAN口②将另一端的电缆连接到互联网服务提供商(ISP)的调制解调器1.2 连接计算机①将计算机连接到路由器的LAN口②确保计算机网络设置为自动获得IP地质2.登录路由器管理界面2.1 打开网页浏览器2.2 在浏览器地质栏输入默认的路由器管理界面IP地质(例如.192.16①)2.3 输入用户名和密码登录路由器管理界面3.基本网络设置3.1 修改管理密码①在路由器管理界面中找到“系统管理”或类似选项②设置新的管理密码并确认保存3.2 更新路由器固件①在路由器管理界面中找到“系统升级”或类似选项②相应的固件文件并进行升级3.3 配置网络名称(SSID)①在路由器管理界面中找到“无线设置”或类似选项②输入新的网络名称(SSID)并确认保存3.4 配置密码①在路由器管理界面中找到“无线设置”或类似选项②设置新的无线密码并确认保存3.5 配置IP地质分配①在路由器管理界面中找到“局域网设置”或类似选项②设置IP地质分配方式为DHCP(自动获取)4.高级网络设置4.1 配置端口转发①在路由器管理界面中找到“虚拟服务器”或类似选项②添加需要转发的端口号和对应的内部IP地质4.2 配置端口触发①在路由器管理界面中找到“端口触发”或类似选项②添加需要触发的端口范围和对应的触发条件4.3 配置静态路由①在路由器管理界面中找到“静态路由”或类似选项②添加需要配置的网络地质和对应的出口或下一跳选项5.安全设置5.1 配置防火墙①在路由器管理界面中找到“防火墙”或类似选项②配置需要开放或关闭的端口5.2 启用MAC地质过滤①在路由器管理界面中找到“无线设置”或类似选项②添加允许或禁止连接的MAC地质5.3 启用网络地质转换(NAT)①在路由器管理界面中找到“NAT”或类似选项②启用NAT并确认保存6.附件本文档涉及附件:●路由器配置截图●路由器固件升级文件●其他相关配置文件7.法律名词及注释●IP地质:Internet Protocol Address,互联网协议地质,用于标识网络设备的唯一地质。
静态路由表配置实例当一个局域网内存在2台以上的路由器时,由于其下主机互访的需求,往往需要设置路由。
由于网络规模较小且不经常变动,所以静态路由是最合适的选择。
随着宽带接入的普及,很多家庭和小企业都组建了局域网来共享宽带接入。
而且随着局域网规模的扩大,很多地方都涉及到2台或以上路由器的应用。
当一个局域网内存在2台以上的路由器时,由于其下主机互访的需求,往往需要设置路由。
由于网络规模较小且不经常变动,所以静态路由是最合适的选择。
本文作为一篇初级入门类文章,会以几个简单实例讲解静态路由,并在最后讲解一点关于路由汇总(归纳)的知识。
由于这类家庭和小型办公局域网所采用的一般都是中低档宽带路由器,所以这篇文章就以最简单的宽带路由器为例。
(其实无论在什么档次的路由器上,除了配置方式和命令不同,其配置静态路由的原理是不会有差别的。
)常见的1WAN口、4LAN口宽带路由器可以看作是一个最简单的双以太口路由器+一个4口小交换机,其W AN 口接外网,LAN口接内网以做区分。
路由就是把信息从源传输到目的地的行为。
形象一点来说,信息包好比是一个要去某地点的人,路由就是这个人选择路径的过程。
而路由表就像一张地图,标记着各种路线,信息包就依靠路由表中的路线指引来到达目的地,路由条目就好像是路标。
在大多数宽带路由器中,未配置静态路由的情况下,内部就存在一条默认路由,这条路由将LAN口下所有目的地不在自己局域网之内的信息包转发到WAN口的网关去。
宽带路由器只需要进行简单的WAN 口参数的配置,内网的主机就能访问外网,就是这条路由在起作用。
本文将分两个部分,第一部分讲解静态路由的设置应用,第二部分讲解关于路由归纳的方法和作用。
下面就以地瓜这个网络初学者遇到的几个典型应用为例,让高手大虾来说明一下什么情况需要设置静态路由,静态路由条目的组成,以及静态路由的具体作用。
例一:最简单的串连式双路由器型环境这种情况多出现于中小企业在原有的路由器共享Internet的网络中,由于扩展的需要,再接入一台路由器以连接另一个新加入的网段。
实训报告实训一路由基本配置1、实验目的:路由器基本配置及ip设置2、拓扑结构图Router0 fa0/0: 192.168.11.1Fa0/1:192.168.1.1Router1 fa0/0: 192.168.11.2Fa0/1:192.168.2.1Znn1:192.168.1.2Znn2:192.168.2.23、实验步骤Router1Router>en 用户模式进入特权模式Router#conf t 特权模式进入全局模式Enter configuration commands, one per line. End with CNTL/Z.Router(config)#host rznn1 改名字为rznn1rznn1(config)#int fa0/0 进入fa0/0端口rznn1(config-if)#ip add 192.168.11.1 255.255.255.0 设置ip地址rznn1(config-if)#no sh 激活rznn1(config)#int fa0/1rznn1(config-if)#ip add 192.168.1.1 255.255.255.0rznn1(config-if)#no shrznn1#copy run star 保存rznn1#conf trznn1(config)#enable secret password 222 设置密文rznn1#show ip interface b 显示Interface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.11.1 YES manual up up FastEthernet0/1 192.168.1.1 YES manual up up Vlan1 unassigned YES manual administratively down downrouter 2outer>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host rznn2rznn2(config)#int fa0/0rznn2(config-if)#ip add 192.168.11.2 255.255.255.0rznn2(config-if)#no shrznn2(config)#int fa0/1rznn2(config-if)#ip add 192.168.2.1 255.255.255.0rznn2(config-if)#no shrznn2#copy run starrznn2#conf trznn2(config)#enable secret 222rznn2#show ip interface bInterface IP-Address OK? Method Status ProtocolFastEthernet0/0 192.168.11.2 YES manual up upFastEthernet0/1 192.168.2.1 YES manual up upVlan1 unassigned YES manual administratively down down实训二1、远程登录、密码设置及验证为路由器开设telnet端口,PC机可以远程登陆到Rznn3(Router 1) 拓扑结构图Router0:192.168.1.1Pc:192.168.1.2步骤rznn3>rznn3>enrznn3#conf tEnter configuration commands, one per line. End with CNTL/Z.rznn3(config)#no ip domain lookuprznn3(config)#line cons 0rznn3(config-line)#password znnrznn3(config-line)#loginrznn3(config-line)#no exec-trznn3(config-line)#logg syncrznn3(config-line)#exitrznn3(config)#int fa0/0rznn3(config-if)#ip add 192.168.1.1 255.255.255.0rznn3(config-if)#no shrznn3(config-if)#exitrznn3(config)#line vty 0 4 打通五个端口rznn3(config-line)#password cisco 设置密码rznn3(config-line)#login 保存rznn3(config-line)#exit4、测试:实训三命令组1、目的:八条命令(no ip domain lookup\line cons 0\password\login\no exec-t\logg sync\show version\reload\copy running-config startup-config)\show cdp neighbors)2、拓扑结构图Router0 fa0/0: 192.168.11.1Router1 fa0/0: 192.168.11.23、步骤rznn1#conf tEnter configuration commands, one per line. End with CNTL/Z.1、rznn1(config)#no ip domain lookup 取消域名查找转换2、rznn1(config)#line cons 0 打开cons 0端口3、rznn1(config-line)#password znn 设置密码为znnrznn1(config-line)#login 保存rznn1(config-line)#no exec-t 设置永不超时4、rznn1(config-line)#logg sync 产生日志5、rznn1#show version 显示思科路由系统版本信息Cisco IOS Software, 2800 Software (C2800NM-ADVIPSERVICESK9-M), V ersion 12.4(15)T1, RELEASE SOFTWARE (fc2)Technical Support: /techsupportCopyright (c) 1986-2007 by Cisco Systems, Inc.Compiled Wed 18-Jul-07 06:21 by pt_rel_team6、rznn1#show cdp neighbors 查看路由器连接的相邻路由器的相关信息Capability Codes: R - Router, T - Trans Bridge, B - Source Route BridgeS - Switch, H - Host, I - IGMP, r - Repeater, P - PhoneDevice ID Local Intrfce Holdtme Capability Platform Port IDrznn2 Fas 0/0 139 R C2800 Fas 0/07、rznn1#copy running-config startup-config 保存刚才指令Destination filename [startup-config]? startup-configBuilding configuration...[OK]8、rznn1#reload 重启路由器Proceed with reload? [confirm]System Bootstrap, V ersion 12.1(3r)T2, RELEASE SOFTW ARE (fc1)Copyright (c) 2000 by cisco Systems, Inc.cisco 2811 (MPC860) processor (revision 0x200) with 60416K/5120K bytes of memorySelf decompressing the image :########################################################################## [OK] Restricted Rights Legendrznn1#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.11.1 YES manual up up FastEthernet0/1 192.168.1.1 YES manual up upVlan1 unassigned YES manual administratively down down9、rznn1(config-if)#ip add 192.168.3.1 255.255.255.0 重置ip地址rznn1#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.3.1 YES manual up up FastEthernet0/1 192.168.1.1 YES manual up upVlan1 unassigned YES manual administratively down down实训四发现协议1、实训目的通过发现协议显示路由器相邻路由的端口信息2、拓扑结构Router0:192.168.11.1Router1:fa0/0 192.168.11.2Fa0/1 192.168.12.1Router2:192.168.12.23、步骤R1路由器Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r1r1(config)#int fa0/0r1(config-if)#ip add 192.168.11.1 255.255.255.0r1(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to upr1(config-if)#r1(config-if)#exitr1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoler1#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.11.1 YES manual up down FastEthernet0/1 unassigned YES manual administrative ly down downVlan1 unassigned YES manual administratively down downR2 路由器Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r2r2(config)#int fa0/0r2(config-if)#ip add 192.168.11.2 255.255.255.0r2(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up r2(config-if)#exitr2(config)#exitr2#%SYS-5-CONFIG_I: Configured from console by consoler2#conf tEnter configuration commands, one per line. End with CNTL/Z.r2(config)#int fa0/0r2(config-if)#int fa0/1r2(config-if)#ip add 192.168.12.1 255.255.255.0r2(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/1, changed state to upr2(config-if)#exitr2(config)#exitr2#%SYS-5-CONFIG_I: Configured from console by consoler2#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.11.2 YES manual up up FastEthernet0/1 192.168.12.1 YES manual up down Vlan1 unassigned YES manual administratively down downR3路由器Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r3r3(config)#int fa0/0r3(config-if)#ip add 192.168.12.2 255.255.255.0r3(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up r3(config-if)#exitr3(config)#exitr3#%SYS-5-CONFIG_I: Configured from console by consoler3#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.12.2 YES manual up up FastEthernet0/1 unassigned YES manual administratively down downVlan1 unassigned YES manual administratively down downR1发现邻居r1#show cdp neighborsCapability Codes: R - Router, T - Trans Bridge, B - Source Route BridgeS - Switch, H - Host, I - IGMP, r - Repeater, P - PhoneDevice ID Local Intrfce Holdtme Capability Platform Port IDr2 Fas 0/0 165 R C2800 Fas 0/0R2发现邻居r2#show cdp neighborsCapability Codes: R - Router, T - Trans Bridge, B - Source Route BridgeS - Switch, H - Host, I - IGMP, r - Repeater, P - PhoneDevice ID Local Intrfce Holdtme Capability Platform Port IDr1 Fas 0/0 176 R C1841 Fas 0/0r3 Fas 0/1 130 R C1841 Fas 0/0R3发现邻居r3#show cdp neighborsCapability Codes: R - Router, T - Trans Bridge, B - Source Route BridgeS - Switch, H - Host, I - IGMP, r - Repeater, P - PhoneDevice ID Local Intrfce Holdtme Capability Platform Port IDr2 Fas 0/0 166 R C2800 Fas 0/14、总结show 命令(1)show ip interface b (显示端口ip信息)(2)show version (显示ios版本信息)(3)show running-config (显示刚才使用的命令配置信息)(4)show cdp neighbors (显示发现邻居直连设备信息)(5)show interface (显示所有端口详细信息)实训五静态路由1、实验目的:将不同网段的网络配通(ip route)Ip route语法:ip route 目标地址子网掩码相邻路由器接口地址Show ip route2、试验拓扑:Router0:192.168.11.1Router1:fa0/0 192.168.11.2Fa0/1 192.168.12.1Router2:192.168.12.23、实验步骤:Router1Router>enRouter#conf tRouter(config)#host r1r1(config)#int fa0/0r1(config-if)#ip add 192.168.11.1 255.255.255.0r1(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to upr1(config-if)#exitr1(config)#exitr1#show ip interface bInterface IP-Address OK? Method Status ProtocolFastEthernet0/0 192.168.11.1 YES manual up downFastEthernet0/1 unassigned YES manual administratively down downVlan1 unassigned YES manual administratively down downr1#%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up r1#ping 192.168.12.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.1, timeout is 2 seconds: .....Success rate is 0 percent (0/5)r1#conf tEnter configuration commands, one per line. End with CNTL/Z.r1(config)#ip route 192.168.12.0 255.255.255.0 192.168.11.2r1(config)#exitr1#ping 192.168.12.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.1, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 31/31/32 msr1#ping 192.168.12.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.2, timeout is 2 seconds: .....Success rate is 0 percent (0/5)r1#ping 192.168.12.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.2, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 47/62/78 msr1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setC 192.168.11.0/24 is directly connected, FastEthernet0/0S 192.168.12.0/24 [1/0] via 192.168.11.2Router3Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r3r3(config)#int fa0/0r3(config-if)#ip add 192.168.12.2 255.255.255.0r3(config-if)#no sh%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up r3(config-if)#exitr3(config)#exitr3#%SYS-5-CONFIG_I: Configured from console by consoler3#show ip interface bInterface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.12.2 YES manual up up FastEthernet0/1 unassigned YES manual administratively down downVlan1 unassigned YES manual administratively down downr3#conf tEnter configuration commands, one per line. End with CNTL/Z.r3(config)#ip route 192.168.11.0 255.255.255.0 192.168.12.1r3(config)#exitr3#ping 192.168.11.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.11.2, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 31/31/32 msr3#ping 192.168.11.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.11.1, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 62/62/63 msr3#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setS 192.168.11.0/24 [1/0] via 192.168.12.1C 192.168.12.0/24 is directly connected, FastEthernet0/04、默认路由Route 1r1>enr1#conf tEnter configuration commands, one per line. End with CNTL/Z.r1(config)#no ip route 192.168.12.0 255.255.255.0 192.168.11.2%No matching route to deleter1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoler1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setC 192.168.11.0/24 is directly connected, FastEthernet0/0r1#conf tEnter configuration commands, one per line. End with CNTL/Z.r1(config)#ip route 0.0.0.0 0.0.0.0 192.168.11.2r1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoler1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.11.2 to network 0.0.0.0C 192.168.11.0/24 is directly connected, FastEthernet0/0S* 0.0.0.0/0 [1/0] via 192.168.11.2r1#ping 192.168.12.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.1, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 16/28/31 msr1#ping 192.168.12.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.2, timeout is 2 seconds: Success rate is 100 percent (5/5), round-trip min/avg/max = 62/62/63 msRoute 3r1>enr1#conf tEnter configuration commands, one per line. End with CNTL/Z.r1(config)#no ip route 192.168.12.0 255.255.255.0 192.168.11.2%No matching route to deleter1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoler1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setC 192.168.11.0/24 is directly connected, FastEthernet0/0r1#conf tEnter configuration commands, one per line. End with CNTL/Z.r1(config)#ip route 0.0.0.0 0.0.0.0 192.168.11.2r1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoler1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.11.2 to network 0.0.0.0C 192.168.11.0/24 is directly connected, FastEthernet0/0S* 0.0.0.0/0 [1/0] via 192.168.11.2r3#ping 192.168.11.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.11.1, timeout is 2 seconds: Success rate is 100 percent (5/5), round-trip min/avg/max = 62/62/63 ms实训六动态路由RIP 协议1、实验目的使用配置动态路由启动Rip协议使用到的命令(router rip/network/show ip protocols/show ip route)2、实验拓扑R1 fa0/0 192.168.11.1R2 fa0/0 192.168.11.2fa0/1 192.168.12.1R3 fa0/0 192.168.12.23、实验步骤R1Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z. Router(config)#host r1r1(config)#int fa0/0r1(config-if)#ip add 192.168.11.1 255.255.255.0r1(config-if)#no shr1(config-if)#exitr1(config)#router ripr1(config-router)#network 192.168.11.0r1(config-router)#exitr1(config)#exitr1#%SYS-5-CONFIG_I: Configured from console by consoleR2Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r2r2(config)#int fa0/0r2(config-if)#ip add 192.168.11.2 255.255.255.0r2(config-if)#no shr2(config-if)#exitr2(config)#int fa0/1r2(config-if)#ip add 192.168.12.1 255.255.255.0r2(config-if)#no shr2(config-if)#exitr2(config)#router ripr2(config-router)#network 192.168.11.0r2(config-router)#network 192.168.12.0r2(config-router)#exitr2(config)#exitr2#R3Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z. Router(config)#host r3r3(config)#int fa0/0r3(config-if)#ip add 192.168.12.2 255.255.255.0r3(config-if)#no shr3(config-if)#exitr3(config)#router ripr3(config-router)#network 192.168.12.0r3(config-router)#exitr3(config)#exitr3#%SYS-5-CONFIG_I: Configured from console by console4、实验测试R1r1#show ip protocolsRouting Protocol is "rip"Sending updates every 30 seconds, next due in 10 secondsInvalid after 180 seconds, hold down 180, flushed after 240 Outgoing update filter list for all interfaces is not setIncoming update filter list for all interfaces is not set Redistributing: ripDefault version control: send version 1, receive any version Interface Send Recv Triggered RIP Key-chain FastEthernet0/0 1 2 1Automatic network summarization is in effectMaximum path: 4Routing for Networks:192.168.11.0Passive Interface(s):Routing Information Sources:Gateway Distance Last UpdateDistance: (default is 120)r1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setC 192.168.11.0/24 is directly connected, FastEthernet0/0R 192.168.12.0/24 [120/1] via 192.168.11.2, 00:00:24, FastEthernet0/0 r1#ping 192.168.12.0Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.12.0, timeout is 2 seconds: Success rate is 100 percent (5/5), round-trip min/avg/max = 31/31/32 msR2r2#show ip protocolsRouting Protocol is "rip"Sending updates every 30 seconds, next due in 21 secondsInvalid after 180 seconds, hold down 180, flushed after 240Outgoing update filter list for all interfaces is not setIncoming update filter list for all interfaces is not setRedistributing: ripDefault version control: send version 1, receive any versionInterface Send Recv Triggered RIP Key-chain FastEthernet0/0 1 2 1FastEthernet0/1 1 2 1Automatic network summarization is in effectMaximum path: 4Routing for Networks:192.168.11.0192.168.12.0Passive Interface(s):Routing Information Sources:Gateway Distance Last UpdateDistance: (default is 120)r2#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setC 192.168.11.0/24 is directly connected, FastEthernet0/0C 192.168.12.0/24 is directly connected, FastEthernet0/1R3r3#show ip protocolsRouting Protocol is "rip"Sending updates every 30 seconds, next due in 15 secondsInvalid after 180 seconds, hold down 180, flushed after 240Outgoing update filter list for all interfaces is not setIncoming update filter list for all interfaces is not setRedistributing: ripDefault version control: send version 1, receive any versionInterface Send Recv Triggered RIP Key-chain FastEthernet0/0 1 2 1Automatic network summarization is in effectMaximum path: 4Routing for Networks:192.168.12.0Passive Interface(s):Routing Information Sources:Gateway Distance Last UpdateDistance: (default is 120)r3#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not setR 192.168.11.0/24 [120/1] via 192.168.12.1, 00:00:04, FastEthernet0/0 C 192.168.12.0/24 is directly connected, FastEthernet0/0r3#ping 192.168.11.0Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.11.0, timeout is 2 seconds: Success rate is 100 percent (5/5), round-trip min/avg/max = 31/31/32 ms实训七负载平衡试训目的实现负载平衡实训拓扑R1 fa0/0 192.168.11.1R2 eth0/0/0 192.168.11.2Fa0/0 192.168.12.1Fa0/0 192.168.13.1R3 fa0/0 192.168.12.2Fa0/1 192.168.14.1R4 fa0/0 192.168.13.2Fa0/1 192.168.15.1R5 fa0/0 192.168.14.2Fa0/1 192.168.15.2实训步骤(R1 )r1>enR1#conf tR1(config)#ip route 0.0.0.0 0.0.0.0 192.168.11.2R1(config)#exitr1#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.11.2 to network 0.0.0.0C 192.168.11.0/24 is directly connected, FastEthernet0/0S* 0.0.0.0/0 [1/0] via 192.168.11.2(R2)r2>enr2(config)#ip route 0.0.0.0 0.0.0.0 192.168.12.2r2(config)#ip route 0.0.0.0 0.0.0.0 192.168.13.2r2(config)#exitr2#%SYS-5-CONFIG_I: Configured from console by consoles% Ambiguous command: "s"r2#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.12.2 to network 0.0.0.0C 192.168.11.0/24 is directly connected, Ethernet0/0/0C 192.168.12.0/24 is directly connected, FastEthernet0/0C 192.168.13.0/24 is directly connected, FastEthernet0/1S* 0.0.0.0/0 [1/0] via 192.168.12.2[1/0] via 192.168.13.2(R3)r3>enr3#conf tEnter configuration commands, one per line. End with CNTL/Z.r3(config)#ip route 0.0.0.0 0.0.0.0 192.168.12.1r3(config)#exitr3#%SYS-5-CONFIG_I: Configured from console by consoler3#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.12.1 to network 0.0.0.0C 192.168.12.0/24 is directly connected, FastEthernet0/0C 192.168.14.0/24 is directly connected, FastEthernet0/1S* 0.0.0.0/0 [1/0] via 192.168.12.1(R4)r4>enr4#conf tEnter configuration commands, one per line. End with CNTL/Z.r4(config)#ip route 0.0.0.0 0.0.0.0 192.168.13.1r4(config)#exitr4#%SYS-5-CONFIG_I: Configured from console by consoler4#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.13.1 to network 0.0.0.0C 192.168.13.0/24 is directly connected, FastEthernet0/0C 192.168.15.0/24 is directly connected, FastEthernet0/1S* 0.0.0.0/0 [1/0] via 192.168.13.1(R5)r5>enr5#conf tEnter configuration commands, one per line. End with CNTL/Z.r5(config)#ip route 0.0.0.0 0.0.0.0 192.168.14.1r5(config)#ip route 0.0.0.0 0.0.0.0 192.168.15.1r5(config)#exitr5#%SYS-5-CONFIG_I: Configured from console by consoler5#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is 192.168.14.1 to network 0.0.0.0C 192.168.14.0/24 is directly connected, FastEthernet0/0C 192.168.15.0/24 is directly connected, FastEthernet0/1S* 0.0.0.0/0 [1/0] via 192.168.14.1[1/0] via 192.168.15.1实训测试(R1)r1#ping 192.168.14.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.14.1, timeout is 2 seconds:Success rate is 100 percent (5/5), round-trip min/avg/max = 62/84/94 ms (R5)r5#ping 192.168.11.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.11.1, timeout is 2 seconds: Success rate is 100 percent (5/5), round-trip min/avg/max = 79/91/94 ms实训八DHCP 协议配置实训目的全网配通实训拓扑Fa0/0 192.168.11.1Fa0/1 192.168.12.1实训步骤Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#host r1r1(config)#int fa0/0r1(config-if)#ip add 192.168.11.1 255.255.255.0r1(config-if)#no shr1(config-if)#exitr1(config)#int fa0/1r1(config-if)#ip add 192.168.12.1 255.255.255.0r1(config-if)#no shr1(config-if)#exitr1(config)#ip dhcp pool znn //配置一个根地址池znnr1(dhcp-config)#network 192.168.11.0 255.255.255.0 //为所有客户机动态分配的地址段r1(dhcp-config)#default-router 192.168.11.1 //为客户机配置默认的网关r1(dhcp-config)#dns-server 192.168.11.1 //为客户机配置DNS服务器r1(dhcp-config)#exitr1(config)#ip dhcp pool znn1。
本地局域网互联(路由协议配置)任务一实验目的:1 掌握路由协议的配置方法;2 理解路由协议的工作过程和使用环境;3 掌握利用路由器连接本地局域网的方法;试验设备:1.DCR-1700或者DCR-2600 路由器一台2. DCRS-3926S交换机一台3. PC机,网线,CONSOLE 线实验拓扑:实验步骤:1.Router#deletethis file will be erased,are you sure?(y/n)y no such fileRouter#writeSaving current configuration...OK!Router#rebootDo you want to reboot the router(y/n)?yPlease wait.. //恢复出厂设置2.Router#show ip route //查看IP路由表Codes: C - connected, S - static, R - RIP, B - BGP, BC - BGP connectedD - DEIGRP, DEX - external DEIGRP, O - OSPF, OIA - OSPF inter areaON1 - OSPF NSSA external type 1, ON2 - OSPF NSSA external type 2OE1 - OSPF external type 1, OE2 - OSPF external type 2DHCP - DHCP typeVRF ID: 0 //没有路由表项3.Router#configRouter_config#interface fRouter_config#interface fastEthernet 0/0Router_config_f0/0#ip address 192.168.2.1 255.255.255.0Router_config_f0/0#exit Router_config#interface eRouter_config#interface ethernet 0/1Router_config_e0/1#ip address 192.168.1.1 255.255.255.0//设置路由器两个以太网接口IP地址4.VRF ID: 0C 192.168.1.0/24 is directly connected, Ethernet0/1 C 192.168.2.0/24 is directly con nected, FastEthernet0/0 //直通路由5.测试PC1与测试计算机的连同性。
内蒙古电子信息职业技术学院课程实训实训题目:计算机网络设备配置实训报告专业:计算机网络技术班级:计网092姓名:丽娜学号:092022053目录第一章实训概述 (3)第二章实训环境及拓扑结构 (3)2.1 硬件环境 (3)2.2 软件环境 (4)2.3 拓扑结构 (4)第三章实训要求 (6)3.1 网络组件与规划 (6)3.1.1 网络拓扑连接与IP规划 (6)3.2 项目实施 (7)3.2.1 总公司网络实施 (7)3.2.2 沈阳办事处网络配置 (9)3.2.3 广州办事处网络配置 (9)3.2.4 重庆分公司网络配置 (9)第四章任务分配及具体内容 (10)4.1 路由器RA的配置 (10)4.1.1 IP地址的配置 (10)4.1.2 路由功能 (11)4.1.3 安全功能 (11)4.1.4 链路功能 (12)4.1.5 管理功能 (13)4.1.6 服务质量 (13)第五章总结 (13)第一章实训概述1、贯彻坚强实践环节和理论联系实际的教学原则,增加学生对专业知识了解的深度及广度,培养学生运用所学知识和技能独立完成复杂网络设备配置的能力。
2、通过实训,开阔学生眼界和知识面,获得计算机网络设备安装和维护的感性认识。
与此同时安排适量的讲课或讲座,促进理论同实践的结合,为面向就业的网络专业学生打下坚实基础。
3、实习中使学生了解专业、热爱专业,激发学习热情,提高专业适应能力,进一步提升网络专业学生网络设备的配置管理能为和网络故障的处理能力。
4、通过对专业、行业、社会的了解,认识今后的就业岗位和就业形式,使学生明确学习方向,努力探索学习与就业的结合点,而发挥学习的主观能动性。
第二章实训环境及拓扑结构2.1 硬件环境2.2 软件环境2.3 拓扑结构如图2-3所示:计算机网络设备配置实训报告5第三章实训要求3.1 网络组件与规划3.1.1 网络拓扑连接与IP规划根据下表和网络拓扑图,将所有连接起来。
IPv6网络协议配置手册前言读者对象●网络工程师●技术推广人员●网络管理人员适用范围本手册适用于迈普路由器6.1.X的版本及对应的设备。
本书约定命令行关键字用加粗表示;命令行参数用斜体表示。
大括号“{ }”表示括号中的选项是必选的;中括号“[ ]”表示括号中的选项是可选的;尖括号“<>”表示括号中的信息不被显示出来;方括号“【】”表示括号中的内容需要用户注意;竖线“|”用于分隔若干选项,表示二选一或多选一;正斜线“/”用于分隔若干选项,表示被分隔的各选项是可以被同时选中的;“ 注意”表示需要读者注意的事项,是配置系统的关键之处,希望用户能认真阅读。
“ 注”表示对前面内容的注解;“ 图解”表示对图例的文字解释。
声明由于产品版本升级或其它原因,本手册内容会不定期进行更新。
除非另有约定,本手册仅作为使用指导,本手册中的所有陈述、信息和建议不构成任何明示或暗示的担保。
目录第1章简介 (1)第2章IPV6配置 (2)2.1 简介 (2)2.2 基本指令描述 (2)2.3 监控和调试 (4)2.3.1 监控命令 (4)2.3.2 调试命令 (5)2.3.3 监控命令实例 (5)2.3.4 监控命令实例 (6)第3章ICMPV6配置 (8)3.1 简介 (8)3.2 基本指令描述 (8)3.3 监控和调试 (13)3.3.1 监控命令 (13)3.3.2 调试命令 (13)第4章DNSV6配置 (13)4.1 简介 (14)4.2 基本指令描述 (14)4.3 监控和调试 (15)4.3.1 监控命令 (15)第1章简介本文主要讲述IPv6协议,ICMPv6协议和DNSv6协议在迈普设备中的配置方法。
本章主要内容:●IPv6协议●ICMPv6协议●DNSv6协议第2章IPv6配置本节主要内容:●IPv6简介●IPv6基本指令描述●IPv6监控与调试2.1简介随着IP网络规模和业务的迅速发展,IP网络的用户数急剧增加,正因为如此,IP网络也暴露出越来越多的问题,如地址空间不足、QoS、安全问题等。
IP路由协议的配置实例Cisco IOS支持的协议有:内部网关协议(它是在一个自治系统内部交换路由信息的路由协议)----- IGRP, EIGRP, OSPF, RIP 和 IS-IS等等.外部网关协议(它是为连接两个或多个自治系统的路由协议)----- BGP 和EGP等等.选择路由协议的原则选择一个路由协议是一个非常复杂的工作.当选择路由协议,参考以下几点: 网络的大小和复杂性支持可变长掩码(VLSM).Enhanced IGRP,IS-IS,OSPF和静态路由支持可变长掩码网络流量大小安全需要网络延迟特性下面就分别介绍各种路由协议的特点和配置.配置IGRP内部网关路由协议(Interior Gateway Routing Protocol---- IGRP)是一个动态的,长跨度的路由协议,它是Cisco公司八十年代中期设计实现的,在一个自治系统内具有高跨度,适合复杂网络的特点.Cisco's IGRP的实现IGRP的网络延迟,带宽,可靠性和负载都是可由用户配置决定的.IGRP广播三种类型的路由:内部的,系统的和外部的.如图所示.内部的路由是在一台路由器的端口上连接子网的路由.如果一台路由器连接的网络是非子网的,IGRP就不广播内部路由.图 1 :内部,系统和外部路由系统路由是一个自治系统内的路由.Cisco IOS 软件从直连的网络接口上获得系统路由,并把它提供给其它的支持IGRP协议的路由器或访问服务器.系统路由不包括子网信息.外部路由是自治系统之间的路由.IGRP的路由交换默认的,一个运行IGRP路由协议的路由器每90秒广播一次路由信息.如果在270秒内未收到某路由器的回应,它则认为目前该路由器不可到达;若在630秒后仍未有应答,则把有关它的路由信息从路由表中删掉.IGRP的配置指定路由器IGRP协议:功能命令激活IGRP路由,进入路由配置模式 router igrp process number加入网络直连的网段 nework network-number请参阅"Configure IGRP Example",更加详细的资料请看 Cisco CD 或Cisco的主页.配置Enhanced IGRPEnhanced IGRP是Cisco公司开发的IGRP的增强的版本.它使用与IGRP相同的路由算法,但它在许多方面对IGRP作了较大的改进.Cisco's Enhanced IGRP的实现Cisco's Enhanced IGRP提供了以下特性:自动重新分配-----IP IGRP路由可以自动的重新分配到EIGRP中,IP EIGRP 也可以自动的重新分配到IGRP中.如果愿意,也可以关掉重新分配.可扩展的网络-----对于IP RIP,你的网络最大只有15个hops,而当使用EIGRP时,最大可以有224个hops.触发的路由表-----EIGRP并不象IGRP那样经过一定的时间间隔后交换路由信息的,而是只有当路由表有变化时才把路由表广播出去的,叫做触发式的(triggered).支持可变长掩码(VLSM)配置Enhanced IGRP指定EIGRP路由协议:功能命令激活EIGRP路由,进入路由配置模式 router eigrp process number加入网络直连的网段 nework network-number更加详细的资料请看 Cisco CD 或 Cisco的主页.IGRP到EIGRP的迁移在同一个自治系统的IGRP和EIGRP是自动能够重新分配的,而在不同两个自治系统之间,作如下配置:功能命令在路由配置模式下,指定路由重新分配 redistribute protocol [option] 在所有的非IGRP环境下使用相同的metric值 default-metric bandwidth delay reliability loading mtu请参阅"IGRP and EIGRP Redistribution Example",更加详细的资料请看Cisco CD 或 Cisco的主页.配置RIP路由信息协议(Routing Information Protocol ---RIP)是一个相对比较老的,但仍被广泛使用的路由协议.RIP广播一个UDP数据包更换路由信息,每个路由器间隔30秒更换一次路由信息,在180秒内未收到某路由器的回应,它则认为目前该路由器不可到达;若在270秒后仍未有应答,则把有关它的路由信息从路由表中删掉.RIP的配置指定IP RIP路由协议:功能命令激活RIP路由,进入路由配置模式 router rip加入网络直连的网段 nework network-numberRIP到IGRP,EIGRP的迁移功能命令在路由配置模式下,指定路由重新分配 redistribute protocol [option] 在所有的非IGRP环境下使用相同的metric值 default-metric number 请参阅"RIP and EIGRP Redistribution Example",更加详细的资料请看Cisco CD 或 Cisco的主页.配置静态路由在某些环境下,我们需要尽量小的路由交换和其它一些特殊环境下会用到静态路由.功能命令在Global配置模式下,指定网关静态路由 ip route network [mask] address [distance]在Global配置模式下,用串口指定静态路由 ip route network [mask] interface [distance]请参阅"Static Routing Redistribution Configure Example".IP路由协议实例配置Configure IGRP ExampleIGRP and EIGRP Redistribution ExampleRIP and EIGRP Redistribution ExampleStatic Routing Redistribution Configure ExampleRoute Filtering ExampleRedistribution FilteringConfigure IGRP Example假设RouterA连接到130.108.0.0和10.0.0.0这两个直连网段上.RouterA#config terminal (在"#"提示符下)RouterA(config)#router igrp 15 (进入配置模式)RouterA(config-router)#network 130.108.0.0 (进入路由配置子模式) RouterA(config-router)#network 10.0.0.0IGRP and EIGRP Redistribution Example在AS 200和AS 100两个自治系统内,分别跑EIGRP和IGRP协议,要想互相通信:Configuration for RouterArouter eigrp 200network 201.222.5.0redistribute igrp 100default-mertic 56 2000 255 1 1500router igrp 100network 131.108.0.0redistribute eigrp 200default-metric 56 2000 255 1 1500RIP and EIGRP Redistribution ExampleConfiguration for RouterArouter ripnetwork 201.222.5.0redistribute eigrp 100default-mertic 3router eigrp 100network 131.108.0.0redistribute ripdefault-metric 56 2000 255 1 1500Static Routing Redistribution Configure Example Configuration for RouterAip route 131.108.1.0 255.255.255.0 131.108.2.1 !router eigrp 1network 192.31.7.0default-metric 10000 100 255 1 1500redistribute staticdistribute-list 3 out static!access-list 3 permit 131.108.0.0 0.0.255.255Route Filtering Example在路由器B上,过滤掉由10.0.0.0发送过来的路由信息,那么在201.222.5.0这个网段上是不能与10.0.0.0这个网通信的.换句话说,在201.222.5.0一端隐藏了10.0.0.0这个网.Configuration for Routerrouter eigrp 1network 131.108.0.0network 201.222.5.0distribute-list 7 out s0!access-list 7 permit 131.108.0.0 0.0.255.255access-list 7 deny 10.0.0.0 0.255.255.255Redistribution Filtering效果同上,但是在两个不同的路由协议下的.Configuration for Routerrouter ripnetwork 201.222.5.0redistribute eigrp 100default-mertic 3!router eigrp 100network 131.108.0.0redistribute ripdefault-metric 56 2000 255 1 1500distribute-list 7 out rip!access-list 7 deny 10.0.0.0 0.255.255.255 access-lsit 7 permit 0.0.0.0 255.255.255.255。