动态路由协议采用自适应路由算法,能够根据网络拓扑的变化而重新计算机最佳路由。由于路由的复杂性,路由算法也是分层次的,通常把路由协议(算法)划分为自治系统(AS)内的(IGP,Interior Gateway Protocol)与自治系统之间(EGP,External Gateway Protocol)的路由协议。
RIP协议基本配置命令
Router(config)#ip classless让路由器支持无类编址,RIPv1是不支持无类IP编址的。
RIP基本配置命令:
Router(config)#router rip
Router(config-router)#network w.x.y.z
可选的配置命令:
Router(config)#no router rip在路由器上关闭RIP协议
Router(config-router)#no network w.x.y.z从RIP协议中移除w.x.y.z网络
Router(config-router)#version 2RIP协议为第2版
Router(config-if)#ip rip send version 2该接口仅发送RIP ver 2报文
Router(config-if)#ip rip send version 1该接口仅发送RIP ver 1报文
Router(conifg-if)#ip rip send version 1 2该接口发送RIP ver 1报文和RIP ver 2报文
Router(config-if)#ip rip receive version 2该接口仅接收RIP ver 2报文
Router(config-router)#no auto-summary关闭路由协议的自动聚合功能
Router(config-router)#ip split-horizon配置水平分割
以下是我今天试验配置的过程(由于这个试验我弄了块3个小时,我自己比较笨,呵呵,会的估计20分钟就弄成了,呵呵,我经常是时间换取成果,呵呵)(由于其中涉及很多的无用命令,还有重复性操作,我就没有列出,仅供自己参考,呵呵)
下面是第一个pc机得ip配置示意图
//下面是第一个路由器的配置过程
--- System Configuration Dialog ---
Continue with configuration dialog? [yes/no]: no
% Please answer 'yes' or 'no'.
Continue with configuration dialog? [yes/no]: no
Press RETURN to get started!
Router>en
Router>enable
Router#confi
Router#configure t
Enter configuration commands, one per line.End with CNTL/Z.
Router(config)#hostname Router
Router(config)#hostname Router0
Router0(config)#int
Router0(config)#interface se
Router0(config)#interface serial0/2/0
Rout