Detailed illustration of OSPF protocol

Source: Internet
Author: User


OSPF is a link State Routing Protocol Based on SPF algorithms.

Under www.2cto.com, Ma summarized the detailed work process of this agreement and hoped to help you ......


When a new router is added to an OSPF area, the OSPF protocol is working. If you can describe this figure in detail, basically, you can master the OSPF protocol. The following is an analysis of this figure.

First, you need to know that a router running the OSPF protocol will eventually store three tables: the neighbor table, the topology table, and the route table. The following describes how the three tables are generated and how the OSPF protocol works.
(1) create a neighbor table
A new router added to the OSPF area must first establish an adjacent relationship with the neighbor router. The process is as follows:
Www.2cto.com
Figure 1

Figure 2

Figure 3
In the preceding three steps, the newly added vro and its neighbor vro have established an adjacent relationship. (2) create a topology table
When creating a topology table at www.2cto.com, the newly added vro must go through the pre-start status, switching status, loading status, and full adjacent status. The following describes the process as an example:

Figure 1

Figure 2

Figure 3
After the above four steps, the data topology of all routers in the OSPF area is synchronized. (3) Each router then runs the SPF algorithm based on the generated region-wide data topology to generate route entries that reach the target network.
After the above three steps, the OSPF protocol basically ends.
Note: There are several important issues in the above process.
1. The Management Distance of this protocol is 110, and the OSPF route process ID must be 1-, and only has local meaning, the route process IDs of different routers can be different, and the region IDs are between 0 and 4294967295. When the region value is 0, this region is called the trunk region.
Www.2cto.com
2. confirm that the router ID follows the following sequence:
The router ID specified by the router ID command has the highest priority.
If this parameter is not specified, the IP address of the loop interface with the largest IP address is the route ID.
If no interface is returned, select the router ID with the highest IP address in the UP port.
However, we recommend that you use commands to specify the controllability.
3. Principles of DR election
The first factor is time. The first vro to be started is elected as DR.
If it is started at the same time or re-elected, the interface priority (0-255) is selected as the highest priority DR. By default, the interface priority of multiple access networks is 1, the interface priority of the point-to-point network is 0, and the command for modifying the interface priority is "ip ospf priority". If the interface priority is set to 0, this interface will not participate in DR election.

If the first two are the same, check the router ID. The highest router ID is elected as a DR.
DR election is not preemptible unless it is manually re-elected. There are two methods to re-elect DR: one is to restart the router, and the other is to execute the "clear ip ospf process" command.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.