当前位置:网站首页>Hcip notes (4)
Hcip notes (4)
2022-07-18 02:57:00 【sysddyq】
OSPF Open shortest path first protocol
Lu Jia Xuan , Fast convergence , Slightly less resources ( be relative to RIP Come on )
OSPF edition
ospfv1( Days off in the Laboratory ),ospfv2 --- IPV4 ospfv3 ---lPV6
RIPV2 and OSPFV2 The similarities of
1,RIPV2 (224.0.0.9) and ospfv2 (224.0.0.5,224.0.0.6) They all send information in the form of multicast .224.0.0.X The multicast address of --- Local link multicast ---- TTL Set to 1
2,RIPV2 and OSPFV2 Are called classless routing protocols .
3,OSPFV2 and RIPV2 All support manual authentication
4, OSPFV2 and RIPV2 All support equal overhead load balancing
RIP and OSPF Difference point :RIP It can only be used in small networks ,OSPF It can be applied to medium and large networks .OSPF Support structured deployment ( Zoning )
The purpose of regional division : Transfer topology information within the region , Transfer routing information between regions .
Zoning
Area border router ABR
Belong to multiple areas at the same time , An interface corresponds to a region and has an interface in the region 0 in
OSPF If the network has only one area , Such a network is called a single area oSPF The Internet ; If there are multiple areas , It is called multi region OSPF The Internet .
Requirements for area division
1, There must be... Between areas ABR equipment ( There can be multiple ABR equipment , One ABR There can also be multiple areas )
2, Region division must be based on star topology
The middle region of star topology is called backbone region ( Area 0)
Area ID--- Distinguish and calibrate ospf Different areas in the network , from 32 Bit binary structure . The way of expression : Dotted decimal means ; Use decimal system directly to express
OSPF working process
OSPF Data packets of
hello package cycle Find out , Building and keeping neighborhoods alive
hello Time :10s(30s)
dead Time :4 Times hello Time
RID The only global ; use the same pattern ( according to IP Format design of address , from 32 Bit binary structure )
1. Manual configuration Just meet the above two conditions
2. Automatic generation
1. First, check whether the device is equipped with a loopback interface , If it exists, select the loopback interface IP Address as R ID; If there are multiple loopback interfaces , Then the one with the largest value will be selected as RID.
2. If there is no loopback interface , Then the... Of the physical interface of the device will be taken IP Address as RID, If there are multiple physical interfaces , Then the one with the largest value will be selected as RID.
DBD package Database description package
The database for LSDB( Link state database ) LSA--- Link status notification
LSR package Link status request message
according to DBD Package comparison , Based on local unknown LSA Message sending request .
LSU package Link state update message
Really carry LSA Packets of information
LSACK package Link status acknowledgement message
OSPF There is 30min— Periodic updates .
OSPF State machine
TWo-WAY --- It marks the establishment of neighbor relations
( Matching conditions ) The match is successful , Then you can enter the next state , If you fail , Will stay in the neighborhood , Use only Hello The package is kept alive periodically .
Principal subordinate relationship election --- By comparison RID To carry out ,RID Big for the main , The master can enter the next state first .
Explicit confirmation : adopt ACK Bag to confirm Implicit confirmation : Not through ACK Bag to confirm , Confirm by serial number
Use here DBD Package to complete the master-slave relationship election is mainly to distinguish from the previous neighbor state .
FULL state --- It marks the establishment of adjacency . The purpose is to distinguish from the neighbor state . Neighbor status can only be used hello The package is kept alive periodically , And the adjacent state can send and receive LSA Information .
down state --- start-up ospf after , issue hello After the package, go to the next state init( initialization ) state --- received Hello Package contains local RID, Then enter the next state
Two-way( Two-way communication ) state --- It marks the establishment of neighbor relations ( Matching conditions ) Matching failure , Will stay in the neighborhood , Use only Hello The package is kept alive periodically ; If the match is successful, it will enter the next state exstart( Pre start ) state -- Use a that does not carry data DBD Package for master-slave relationship election ,RID Big for the main , The master can enter the next state first exchange ( Quasi exchange ) state --- Use... With directory information DBD Package for directory sharing loading ( load ) state --- Based on DBD package , Use LSR/LSU/LSACK Three kinds of packet acquisition are unknown LSA Information . FULL state --- It marks the establishment of adjacency .|
OSPF Working process of
After the startup configuration is completed ,ospf Multicast will be provided to all interfaces running the protocol locally 224.0.0.5 In the form of hello package ; hello The bag will carry your own local RID And local known neighbors RID; after , Record the collected neighborhood relationships in a local table --- Neighborhood watch . After the neighbor relationship is established , Match the sacrificial parts . Failure , Stay in the neighborhood , Use only hello The package is kept alive periodically ; If the matching is successful, the adjacency relationship will be established . First , Use a that does not carry data DBD Package for master-slave relationship election , after , Use... With information DBD Package shared database directory information . after , Local use LSR/LSU/LSACK Three kinds of packets get unknown LSA Information . after , Complete the establishment of local database , Generate database tables ---LSDB. Last , Based on LSA Information , Generate directed graph and shortest path tree , after , Calculate the local routing information to the unknown network segment . Add this routing information to --- Routing table .
After convergence ,ospf Still every 10s (30s) send out hello The package is kept alive periodically ; every other 30MIN Make a periodic update .
Structural mutation
1, Add a new network segment --- Trigger update , Change the information immediately through LSU The package passes out , need ACK confirm . 2, Disconnect a network segment --- Trigger update , Change the information immediately through LSU The package passes out , need ACK confirm . 3, Unable to communicate ——dead time
OSPF The basic configuration of
1, start-up ospf process [r1]ospf 1 router-id 1.1.1.1
2, Create area [r1-ospf-1]area 0 [r1-ospf-1-area-0.0.0.0]
3, Declare
[r1-ospf-1-area-0.0.0.0]network 12.0.0.1 0.0.0.0( Unmask , Continuous 0 And continuous 1 form ,0 The corresponding bit is immutable ,1 Corresponding to variable . You can make accurate announcements , You can also declare the scope )
Purpose 1, Activate interface ;2, Publish route
[r1]display ospf peer --- see ospf My neighbor table
[r1]display ospf peer brief --- View neighbor profile
[r1]display ospf lsdb --- View database tables
[r1]display ospf lsdb router 2.2.2.2 --- Expand a LSA Information
Huawei equipment definition ospf The default priority of the protocol is --10
COST = Reference bandwidth / Real bandwidth --- The default reference bandwidth of Huawei equipment is 100Mbps
If the cost value is less than 1 Decimals of , Then directly follow 1 To calculate ; If it is greater than 1 Decimals of , Then take the integer part directly .
[r1-ospf-1]bandwidth-reference 1000 Change reference bandwidth , Modification requires that all OSPF The equipment of is changed to the same
边栏推荐
- XPath actual combat: climbing the learning ape land (Part 1)
- 昇腾AI创新大赛两大赛道怎么选?拿好这篇攻略就够了!
- 元宇宙大爆发是谁在“跑马圈地”?
- 08 use timer to control LED flashing
- Wechat applet uni app uses uni Getuserprofile to realize wechat authorized login (with source code)
- Efficient development of harmonyos course applications based on ETS
- [design topics] project summary of graduation design topics based on C51 single chip microcomputer - 500 cases
- 1、OLED简单驱动
- 【MySQL】表的内外链接
- 51nod 1278 相离的圆
猜你喜欢

Aike AI frontier promotion (7.15)

PowerDesigner安装教程

How can im make enterprise telecommuting simpler and more efficient?

2022-04-21 unity entry 8 - sound system

Efficient development of harmonyos course applications based on ETS

A---DMA串口通信

Getting started with esp8266 Lua

RobotFramework进阶(一)集成Pycharm及UI自动化用例编写

MQTT---SUBSCRIBE和SUBACK

Basic concepts
随机推荐
07 printf重定向
The end of kotlin plug-in and the rise of viewbinding
Google proposes the reliability machine learning model plex: let the large model put forward appropriate prediction results for out of distribution data
mysql中出现Unit mysql.service could not be found 的解决方法
Landing DDD (7) - some misunderstandings in tactical design
One of MySQL artifact locks
加密市场的牛熊周期;NFT 定义的争论
Web3离爆发还差什么?
欧拉Talk | 开发者社区体验坦白局7月14日19:30约起
03 按键控制LED
CCF 202012-1 期末预测之安全指数
Envoyez votre code dans l'espace et développez "le plus grand travail" avec Huawei Cloud
10分钟带你进入Swagger的世界,快来看一看吧
How can im make enterprise telecommuting simpler and more efficient?
Sequence table
【MySQL】多表查询
送你的代碼上太空,與華為雲一起開發'最偉大的作品'
05 USART sending and receiving data (query mode)
A --- DMA serial port communication
HCIP笔记(3)