[Network Engineer] Do you know everything about OSPF routing control? (two)

  1. Router-LSA(1类Type LSA)

1.1. Router-LSA concept

Describe the router's own routing information and topology information

1.2. Router-LSA describes P2P network
Insert picture description here
Insert picture description here

Type: Router ID //LAS type

          LS id:1.1.1.1          //生成这条LSA的路由器的Router ID

          Adv rtr:1.1.1.1        //生成这条LSA的路由器的Router ID

Topological information

Link ID: 3.3.3.3 //Router ID of the neighboring router

Data: 10.1.13.1 //From which interface will this LSA be announced?

Link Type: P-2P //Link type

Metric: 48 //overhead

Routing information

Link ID: 10.1...13.0 //Indicates the network segment of the stub network

Data: 255.255.255.0 //Indicates the network segment mask of the stub network

Link Type: StubNet //Stubnet represents topology information

Metric: 48 //overhead value

Priority: Low //Priority

1.3 Router-LSA describes MA network or NBMA network

Insert picture description here
Insert picture description here

Type: Router ID //LAS type

          LS id:1.1.1.1          //生成这条LSA的路由器的Router ID

          Adv rtr:1.1.1.1   

Topological information

Link ID: 10.1.235.2 //IP address of the DR interface

Data: 10.1.235.3 //From which interface will this LSA be announced?

Link Type: TransNet //Link type

Metric: 48 //overhead

Type1 LAS describes topology information and routing information in P2P links (P2P networks will not have Type2 LSAs)

Type1 LSA only describes topology information in MA/NBMA network

  1. Network-LSA (Type 2 Type LSA)

2.1. Network-LSA concept

            由DR生成,来描述MA/NBMA网络的拓扑信息和路由信息

2.2. Network-LSA describes the MA/NBMA network
Insert picture description here
Insert picture description here

Type: Network //LSA type

LS id: 10.1.235.2 //IP address of the DR interface

Adv rtr:2.2.2.2 //DR的Router ID

Net mask: 255.255.255.0 //Network mask

Priority: Low //Priority

Attached Router: 2.2.2.2 //OSPF router connected to this network segment

Attached Router:3.3.3.3

Attached Router:4.4.4.4

Type1/2 LSAs can only be flooded in the area and cannot be transmitted to other areas

  1. SPF calculation process

3.1. LSDB in OSPF area

               同一区域的所有OSP

Insert picture description here

All OSPF routers in the same area have the same LSDB
3.2. SPF algorithm

3.2.1. Building the SPF trunk

Construct an SPF trunk based on the topology information in Router-LSA and Network-LSA

   第一步:首先路由器查看自己的Router-LSA

Insert picture description here

  1. Each router in the OSPF network has its own topology tree, and each router is the root node

  2. Take the figure above as an example, RA checks its own Router-LSA.

I found that I have two topology information, one is P2P and the other is MA

In the P2P link, you will know that there is a neighbor Router ID 3.3.3.3

In the MA, you will find that there is a DR of 10.1.12.2, and then continue to search for Network-LSA, you can find that there are only two routers in this MA network, and one neighbor is 2.2.2.2
Insert picture description here

Step 2: First, the router checks the Router-LSA of other routers
Insert picture description here

  1. At this time RA knows that it has a neighbor 2.2.2.2, it will check the Router-LSA of 2.2.2.2

  2. Found that the neighbor 2.2.2.2 has three topological information, one is P2P, two are MA, and one of the MA is connected to itself

    In the P2P link, you will know that there is a neighbor Router ID 4.4.4.4

    One of the MA (DR 10.1.12.2) is connected to itself and has been calculated

    Another MA (DR 10.1.235.2), and then search for Network-LSA, and found that there are two routers in this MA network, namely 3.3.3.3 and 5.5.5.5
    Insert picture description here

We can see that there are two paths from RA to 3.3.3.3, but the priority will be selected according to the cost.
By looking at the subsequent Router-LSA and Network-LSA, we know that the entire topology is described.

3.2.2. Calculate the optimal route

Calculate the optimal route based on the routing information in Router-LSA and Network-LSA
Insert picture description here

After the trunk is constructed, the network segment information is added to the trunk to calculate the optimal route. And generate routing tableInsert picture description here

Guess you like

Origin blog.csdn.net/ZYJY2020/article/details/112568802