当前位置:网站首页>Switches and routers technology - 21 - RIP routing protocol
Switches and routers technology - 21 - RIP routing protocol
2022-08-11 04:52:00 【w Spicy little prince】
目录
一、RIP动态路由协议
1.1 基本概念:
路由信息协议(RIP、Routing Information Protocol).它是一种较为简单的内部网关协议
,主要用于规模较小的网络中.RIP是一种基于距离矢量(Distance-Vector)算法的协议.Pass routing information in a single autonomous system.
RIP使用跳数(Hop Count)to measure the distance to the destination address,称为度量值.在RIP中,默认情况下,路由器到与它直接相连网络的跳数为0,通过一个路由器可达的网络的跳数为1,其余依此类推.也就是说,The metric value is equal to the number of routers from this network to the destination network.为限制收敛时间,RIP规定度量值取0~15之间的整数,大于或等于16的跳数被定义为无穷大,即目的网络or the host is unreachable.由于这个限制,使得RIP不可能在大型网络中得到应用.
每隔30SSend routing update messages to neighboring routers,它通过UDP报文进行路由信息的交换,使用的端口号为520,The corresponding routing entries are learned from neighboring routersR1not directly learnedR3的路由
1.2 Learn the routing process
初始状态
(Obtains directly connected routing information)

启用RIP协议
在in the first update time period,R1、R2、R3Both announce their own routing information,And learn the respective adjacent routing information.

in the second time period,The three routes will announce their learned routes together with the original ones,And learn the respective adjacent routing information.

1.3 RIP的版本
RIPv1
有类路由协议(采用标准子网掩码).
广播更新,Send updates to all directly connected routes.
不支持VLSM(可变长子网掩码,非标准子网掩码).
自动路由汇总,不可关闭
Aggregate long subnet masks into short ones
(192.168.20/24、192.168.10.0/24 汇总成192.168.0.0/16)
不支持不连续子网
10.0.0.0/8 172.16.0.0/24 cannot be aggregated
Router(config)#route rip 默认就是v1版本
RIPv2
无类路由协议(可以使用非标准子网掩码)
组播更新(只会向运行了RIP的路由器发送更新消息)
支持VLSM
自动路由汇总,可以关闭
支持不连续的子网
1.4RIP的配置
1.4.1 RIPv1 的配置
Route rip
Network 网段
路由表中R就是RIP协议学习到的、It will generate routes based on the nearest hop count

First configure each interface of each routerIP地址和子网掩码
然后配置RIP,Let the router announce all the network segments directly connected to him
以路由器0为例
Router(config)#route rip //默认版本v1
Router(config-router)#network 192.168.10.0
Router(config-router)#network 192.168.30.0
Router(config-router)#network 192.168.40.0
Each router needs to complete the advertisement of the directly connected network segment.The configuration is the same as above,Change the network segment
从route0 到route2即从10网段到50There are two ways of network segment,same number of hops,But reach the network segment20The number of hops to go down will be less,所以到达20There will only be one network segment

1.4.2 RIPv12的配置
配置RIP Versin 2版本,多了一条version 2的命令
The biggest advantage is that it supports automatic summary closing,支持不连续子网;The announcement information is sent by multicast

First configure each interface of each routerIP地址和子网掩码
然后配置RIP,配置RIP版本,Then let the router announce all the network segments directly connected to him
to configure the router4为例
Router#conf t
Router(config)#route rip
Router(config-router)#version 2
Router(config-router)#network 192.168.100.0
Router(config-router)#network 192.168.100.64
查看路由器4的路由学习·情况,Shows that it has been successfully learned128和192网段,And aggregated192.168.100.0/24的子网掩码

如果不想要自动汇总,Then you need to use the commandno auto-summary(Only valid if auto-summary is turned off before the announcement)
It needs to be closed before each router advertisement to be effective
Router#conf t
Router(config)#route rip
Router(config-router)#no auto-summary
边栏推荐
- 优化是一种习惯●出发点是“站在靠近临界“的地方
- [Likou] 22. Bracket generation
- "125 Palindrome Verification" of the 10th day string series of LeetCode brushing questions
- zabbix构建企业级监控告警平台
- 交换机和路由器技术-26-OSPF末梢区域配置
- Mysql: set the primary key to automatically increase the starting value
- 解决多线程调用sql存储过程问题
- Summary of c language fprintf, fscanf, sscanf and sprintf function knowledge points
- 交换机和路由器技术-34-动态NAT
- 洛谷P5139 z小f的函数
猜你喜欢
随机推荐
论文笔记:Bag of Tricks for Long-Tailed Visual Recognition with Deep Convolutional Neural Networks
分层架构&SOA架构
洛谷P6586 蒟蒻火锅的盛宴
[Actual combat scene] Mall-discount event design plan
使用百度EasyDL实现森林火灾预警识别
洛谷P7441 Erinnerung
【yolov7系列三】实战从0构建训练自己的数据集
源代码加密技术浅析
Redis:解决分布式高并发修改同一个Key的问题
[Likou] 22. Bracket generation
干货:服务器网卡组技术原理与实践
ALSA音频架构 -- aplay播放流程分析
一种基于共识机制的数字集群终端防失控方案研究
【小记】BatchSize的数值是设置的越大越好吗
I wrote some code in my resume, but I still can't pass the interview
[Web3 series development tutorial - create your first NFT (9)] How to view your NFT in the mobile wallet
ALSA音频架构 -- snd_pcm_open函数分析
利用Navicat Premium导出数据库表结构信息至Excel
交换机和路由器技术-29-OSPF虚链路
async(异步)和await的使用


![[Likou] 22. Bracket generation](/img/f6/435fe9e0b4c1545514d1bf195ffd44.png)






