当前位置:网站首页>Routing strategy
Routing strategy
2022-08-02 00:19:00 【Co_ml】

二、Do multipoint bidirectional redistribution、重发布直连
The environment should be completed firstR7Loopback reposts inOSPF环境,再在R2、R3上进行双向重发布;
此时在OSPF环境中,到R7The loopback route toR4will be issued separatelyR2、R3,At this time, the priority of the route is 150;
进入RIP环境中,The route priority becomes100,假设从R2进入从R3出来,再进入OSPF环境,此时R4You will learn two thingsR7环回的路由(R5,R3),他们的优先级都为150;
因为,R3Selected by priorityR1学习到的7.7.7.0/24(100)环回路由,will be refreshed byR4学习到的7.7.7.0/24(150)环回路由,Republish at this timeR4;
但是由R5传给R4The routing metric of is 3,所以R4会选择R3给他的R7环回的路由(度量为1),此时到R4到R7会形成环路;
when the route is routed byR4传给R5时,The route metric is 2(种子度量+1),R5通过OSPF学习到R7The measure of loopback is also2,and the priority is 150,此时R5到R7Loopback will load balance;
In this case, it is necessary to reasonably use routing policies to solve poor routing,and loop problems.
先将R7loopback for republishing
[r7-ospf-1]import-route direct
再将R3、R2双向重发布,此处列举R2的配置
[r2-ospf-1]import-route rip
[r2-rip-1]import-route ospf
三、路由回馈
由于由OSPF学习到的R3The loop routing its mask is32优先级为10,Access via repostRIP环境,R2Two things will be learnedR3环回的路由(一个掩码32,一个掩码24),但是由RIPThe priority of the learned route is 100,So it chooses to believe byOSPFthe learned route,再传给R1,结果是R1到R3Loop back will go12.1.1.0 网段,选路不佳.
解决办法:
1、将R3Change the network type of the loopback interface tobroadcast
2、Change the mask of the loopback interface to32
Choose a method here1,执行后R2Only in the routing tableR3环回OSPF的路由
[r3]int loop 0
[r3-LoopBack0]ospf network-type broadcast
3.3.3.0/24 OSPF 10 2 D 24.1.1.2 GigabitEthernet0/0/1
四、解决环路
The idea is how to deal with itRIPenvironment by republishingOSPF进来的7.7.7.0/24路由;
解决办法:
1、令R3Do not learn byR1传给它的7.7.7.0/24路由:
Use the prefix list inR3上拒绝7.7.7.0/24网段,但是若R3-R4The physical link fails and cannot be connected,R3cannot be reached7.7.7.0/24,There are no alternate routes.
2、令R3从R1学习到的7.7.7.0/24Routes take precedence over byR4学习到的7.7.7.0/24路由(150)
这样R3choose to believeR4传给它的7.7.7.0/24路由,Solve the loop,And there are backup lines
使用方法2:
[r3]ip ip-prefix hh permit 7.7.7.0 24
****Create a list of prefixes for crawling7.7.7.0/24网段
[r3]route-policy hh permit node 10
Info: New Sequence of this List.
****创建路由策略
[r3-route-policy]if-match ip-prefix hh
****Check the prefix list
[r3-route-policy]apply preference 151
****Change the priority of the routes captured by the prefix list to execute151
[r3-rip-1]preference route-policy hh
****在RIPThe routing strategy is called in
再来查看R3关于7.7.7.0/24的路由表
[r3-rip-1]dis ip ro
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
Destinations : 24 Routes : 24
Destination/Mask Proto Pre Cost Flags NextHop Interface
1.1.1.0/24 RIP 2 1 D 13.1.1.1 GigabitEthernet0/0/1
2.2.2.0/24 RIP 2 2 D 13.1.1.1 GigabitEthernet0/0/1
3.3.3.0/24 Direct 0 0 D 3.3.3.3 LoopBack0
3.3.3.3/32 Direct 0 0 D 127.0.0.1 LoopBack0
3.3.3.255/32 Direct 0 0 D 127.0.0.1 LoopBack0
4.4.4.4/32 OSPF 10 1 D 34.1.1.2 GigabitEthernet0/0/2
5.5.5.5/32 OSPF 10 2 D 34.1.1.2 GigabitEthernet0/0/2
6.6.6.6/32 OSPF 10 3 D 34.1.1.2 GigabitEthernet0/0/2
7.7.7.0/24 O_ASE 150 1 D 34.1.1.2 GigabitEthernet0/0/2
环路问题解决
五、solution routing
此时查看R1的路由表,发现R1到OSPF都是负载均衡,显然不合理;
查看R4的路由表,同理此时R4到RIPAlso load balancing,不合理;
理想状态下:
在RIP中:
R1到R3环回和34.1.1.0/24应该是走13.1.1.0/24
R1到24.1.1.0/24应该是走12.1.1.0/24
R1To other network segments are load balancing
在OSPF中:
R4到R3环回和13.1.1.0/24应该走34.1.1.0/24
R4到12.1.1.0/24应该走24.1.1.0/24
R4到R1环回负载均衡
解决办法:
1、RIP中:
Use the offset list to change its metric
[r2]ip ip-prefix xx permit 3.3.3.0 24
[r2]ip ip-prefix xx permit 34.1.1.0 24
****抓取
[r2]int g0/0/0
[r2-GigabitEthernet0/0/0]rip metricout ip-prefix xx 2
****Enter the interface to call the prefix list,and measure it+2,This route will then become the alternate route
[r3]ip ip-prefix xx permit 24.1.1.0 24
[r3]int g0/0/1
[r3-GigabitEthernet0/0/1]rip metricout ip-prefix xx 2
2、OSPF中:
改变cost-type
[r2]ip ip-prefix haha permit 12.1.1.0 24
[r2]ip ip-prefix haha permit 2.2.2.0 24
****Crawl network segments using prefix lists
[r2]route-policy haha permit node 10
Info: New Sequence of this List.
****创建路由策略
[r2-route-policy]if-match ip-prefix haha
[r2-route-policy]apply cost-type type-1
****The route of the network segment will be selectedcost-type改为type-1
****Because of the default republished routecost-type为type-2
****type-1的优先级大于type-2
****所以OSPF会将type-2route as an alternate route
[r2-route-policy]q
[r2]route-policy haha permit node 20
Info: New Sequence of this List.
****创建一个空表,允许所有
[r2-ospf-1]import-route rip route-policy haha
****在ospfThe routing strategy is called in
[r3]ip ip-prefix haha permit 13.1.1.0 24
[r3]route-policy haha permit node 10
Info: New Sequence of this List.
[r3-route-policy]if-match ip-prefix haha
[r3-route-policy]apply cost-type type-1
[r3-route-policy]q
[r3]route-policy haha permit node 20
Info: New Sequence of this List.
[r3-ospf-1]import-route rip route-policy haha
边栏推荐
- nodeJs--mime模块
- JSP如何使用request获取当前访问者的真实IP呢?
- PHP从txt文件中读取数据的方法
- What is the function of the JSP Taglib directive?
- Ansible中的任务执行控制
- Industrial control network intrusion detection based on automatic optimization of hyperparameters
- 回顾历史5次经济衰退时期:这一次可能会有何不同?
- 为什么要使用MQ消息中间件?这几个问题必须拿下
- JSP out. The write () method has what function?
- els block deformation
猜你喜欢

How to get the best power efficiency in Windows 11?

Disk and file system management
![[21-Day Learning Challenge] A small summary of sequential search and binary search](/img/81/7339a33de3b9e3aec0474a15825a53.png)
[21-Day Learning Challenge] A small summary of sequential search and binary search

security cross-domain configuration

Play NFT summer: this collection of tools is worth collecting

146. LRU cache

短视频seo搜索优化主要内容

TCL:在Quartus中使用tcl脚本语言进行管脚约束

How to solve the error when mysql8 installs make

REST会消失吗?事件驱动架构如何搭建?
随机推荐
利用“栈”快速计算——逆波兰表达式
22.支持向量机—高斯核函数
An overview of the most useful DeFi tools
Win11内存管理错误怎么办?
[头条]笔试题——最小栈
security CSRF Vulnerability Protection
电机原理动图合集
基于相关性变量筛选偏最小二乘回归的多维相关时间序列建模方法
JSP如何使用request获取当前访问者的真实IP呢?
Detailed explanation of Zadig's self-testing and tuning environment technical solution for developers
不了解SynchronousQueue?那ArrayBlockingQueue和LinkedBlockingQueue不会也不知道吧?
460. LFU 缓存
JSP built-in object out object function introduction
回顾历史5次经济衰退时期:这一次可能会有何不同?
TCL: Pin Constraints Using the tcl Scripting Language in Quartus
460. LFU cache
图解LeetCode——1161. 最大层内元素和(难度:中等)
Arduino 基础语法
路由策略
What does the errorPage attribute of the JSP page directive do?