当前位置:网站首页>OSPF protocol summary
OSPF protocol summary
2022-07-03 07:38:00 【joy_ JQ】
OSPF: Open shortest path first protocol
OSPF Data packets of :hello package DBD package LSR package LSU package LACK package
OSPF State machine
Down State start-up OSPF after , send out hello package
Init State After receiving the opposite end hello package , And the package contains RID, Now enter the next state
Two-Way State Mark the establishment of neighbor relationship , At this time, condition matching
Exstart State Use a that does not carry data DBD Package for master-slave relationship election
Exchange State Use... That carries data DBD Package to share database directory information
Loading State Load the opposite DBD Directory information in the package , And then with the local LSDB Compare database directory information , Then decide to send LSA/LSR/LSU package
FULL State It marks the confirmation of adjacency relationship
OSPF working process :
Start in configuration OSPF After completion , Local OSPF It will report to all local running OSPF Protocol router multicast address sending hello package . This hello The packet will carry the local route OSPF Of RID And local known neighbors RID. Then record the collected neighborhood relations to the local OSPF On the neighbor list of { Neighborhood watch }
After the neighbor table is established , Condition matching , Success starts to build adjacency .
After the adjacency relationship is established ,OSPF Both parties who establish the receiving relationship will use the one without data DBD Package for master-slave relationship election . After the election is completed and the master-slave relationship is decided , The leading Party will first use carry LSA Link directory data DBD Share database directory with package . And by sending LSR/LSU/LACK Package request / obtain / Confirm unknown local unknown link LSA Information , Finally, complete the establishment of local database LSDB
Local OSPF The routing protocol is based on the local link state database , To generate a directed graph of the routing topology . Re pass SPF The algorithm transforms a directed graph into a spanning tree , And calculate the best route for the local route to the unknown network segment , Finally, the best routing information is generated and added to OSPF In the routing table
complete OSPF After convergence , There are still cycles between routes (10s/30s) Send each other hello Package to keep alive and every 30 A periodic update is performed once a minute
ospf Basic configuration
[R1]ospf 1 router-id x.x.x.x
[R1] area x
[R1-ospf-1-area-x.x.x.x] network x.x.x.x x.x.x
About OSPF Irregular region problem
Away from the backbone of the non backbone
Discontinuous backbone
Solution :
1.tunnel In the backbone area and illegal ABR Build a tunnel between , The tunnel link is then declared to OSPF Agreement
shortcoming : Periodic hello And update , Including triggering updates , Poor route selection
2. OSPF Virtual link of
[r2]ospf 1
[r2-ospf-1]area 1
[r2-ospf-1-area-0.0.0.1]vlink-peer 4.4.4.4
[r2]display ospf vlink
shortcoming : Two on the virtual chain ABR The problem of periodic resource occupation between
3. Multi process bidirectional republication
In the network , Running multiple routing protocols or different processes of the same protocol, because the protocols cannot communicate and calculate directly , Re publishing is needed to realize route sharing
Re release single point, double point and multi point One way, two-way
[r4]ospf 1
[r4-ospf-1]import-route ospf 2
[r4-ospf-1]q
[r4]ospf 2
[r4-ospf-2]import-route ospf 1
ospf Certification of Ensure the safety of data communication between neighbors
Interface authentication
[r6-GigabitEthernet0/0/1]ospf authentication-mode md5 1 cipher 123456
Regional certification
[r1]ospf 1
[r1-ospf-1]area 1
[r1-ospf-1-area-0.0.0.1]authentication-mode md5 1 cipher 123456
Virtual link authentication
[r10-ospf-1-area-0.0.0.4]vlink-peer 9.9.9.9 md5 1 cipher 123456
Silent interface Resource consumption is large and needs to be closed
[r2]ospf 1
[r2-ospf-1]silent-interface GigabitEthernet 0/0/2
OSPF Of DBD package --- Implicit confirmation of sorting problem
The purpose is to avoid sending and carrying at both ends at the same time LSA Of DBD Headlines , Cause link congestion ; Therefore, in order to keep the order normal ,DBD Implicit confirmation is required ;
Topology is better than routing 1/2LSA The calculated route is better than 3/4/5/7 Class calculated
Internal is better than external 3 Class is better than 4/5/7 class
type 1 Better than type 2 E1 be better than E2,N1 be better than N2,E1 be better than N2,N1 be better than E2;
E1 And N1 meet , or E2 And N2 meet , Compare the total measurement first ( start + Along the way ) Xiaoyou ; The measurement is consistent 5 Class is better than 7 class
Summary
Interregional ABR There are three types that will be passed LSA To summarize
stay ASBR On , Import by republishing 5 class /7 class LSA Get into OSPF Summarize when in the field
Special area
The terminal area : It just keeps 1.2.3 Class LSA stay LSBD On the table
Completely peripheral area :LSDB The database table has only one default route and 1 Classes and 2 class LSA Information
Incomplete ending area (NSSA): Only... Will be saved in the complete terminal area 1 class ,2 class ,3 Class LSA, And this area will no longer accept 4 Classes and 5 class LSA, stay NSSA Intra domain ,5 class LSA Converted to 7 class LSA, Connecting the backbone area ABR It's equivalent to becoming ASBR, conversion 7 Class is 5 class ( Omit 4 class LSA) Send to backbone area
Completely NSSA Area , stay NSSA Further refuse to learn based on the region 3 class LSA
SPF Algorithm : Shortest route first algorithm , The local route selects the optimal solution to reach other routes in the region .
Local routes first choose other routes that can reach directly ( Within the region )
At this time, in the arrived route , Select the next hop route with the lowest cost , And list its direct ( Except for the starting route )
At this time, if there is a route to reach the known existence ( Use the new line to reach the same route ), Then compare the accumulated cost value , Choose the one with low cost
Repeat the previous ②,③ step , Until all the cost values are listed , At this point, you can draw a tree view )
边栏推荐
- 【LeetCode】3. Merge Two Sorted Lists·合并两个有序链表
- Image recognition and detection -- Notes
- 【MindSpore论文精讲】AAAI长尾问题中训练技巧的总结
- OSI knowledge sorting
- Lucene hnsw merge optimization
- Common methods of file class
- 技术干货|昇思MindSpore创新模型EPP-MVSNet-高精高效的三维重建
- Common architectures of IO streams
- TypeScript let与var的区别
- Use of other streams
猜你喜欢
技术干货|昇思MindSpore NLP模型迁移之Roberta ——情感分析任务
Go language foundation ----- 01 ----- go language features
研究显示乳腺癌细胞更容易在患者睡觉时进入血液
JS monitors empty objects and empty references
Analysis of the problems of the 7th Blue Bridge Cup single chip microcomputer provincial competition
PAT甲级 1029 Median
Technical dry goods | hundred lines of code to write Bert, Shengsi mindspire ability reward
技术干货|昇思MindSpore Lite1.5 特性发布,带来全新端侧AI体验
Leetcode 213: 打家劫舍 II
Leetcode 198: 打家劫舍
随机推荐
基于RNA的新型癌症疗法介绍
Robots protocol
技术干货|昇思MindSpore可变序列长度的动态Transformer已发布!
Go language foundation ----- 01 ----- go language features
Technical dry goods Shengsi mindspire innovation model EPP mvsnet high-precision and efficient 3D reconstruction
Vertx metric Prometheus monitoring indicators
[Development Notes] cloud app control on device based on smart cloud 4G adapter gc211
技术干货|关于AI Architecture未来的一些思考
【LeetCode】3. Merge Two Sorted Lists·合并两个有序链表
Collector in ES (percentile / base)
Analysis of the problems of the 7th Blue Bridge Cup single chip microcomputer provincial competition
Vertx's responsive MySQL template
技术干货|昇思MindSpore创新模型EPP-MVSNet-高精高效的三维重建
Technical dry goods | hundred lines of code to write Bert, Shengsi mindspire ability reward
Industrial resilience
HarmonyOS第三次培训笔记
opensips与对方tls sip trunk对接注意事项
Hisat2 - stringtie - deseq2 pipeline for bulk RNA seq
IPv4 address
pgAdmin 4 v6.11 发布,PostgreSQL 开源图形化管理工具