Search

What is OSPF Router ID, OSPF Router ID Selection Algorithm and How to Configure OSPF Router ID

Each Router in an OSPF network needs a unique OSPF Router ID. The OSPF Router ID is used to provide a unique identity to the OSPF Router.

OSPF Router ID is an IPv4 address (32-bit binary number) assigned to each router running the OSPF protocol.

OSPF Router ID should not be changed after the OSPF process has been started and the ospf neighborships are established. If you change the OSPF router ID, we need to either reload the IOS or use "clear ip ospf process" command, for OSPF Router ID change to take effect. Reloading the IOS or using "clear ip ospf process" commad can cause temporary network outage.

OSPF Router ID selection algorithm works as below.

• Any manually configured OSPF Router ID in OSPF Process is selected as the OSPF Router ID.

• If there is no OSPF Router ID configured, the highest IP address on any of the Routers Loopback Interfaces is selected as the OSPF Router ID.

• If there is no Loopback Interfaces configured, the highest IP address on its active interfaces is selected as the OSPF Router ID.

To configure OSPF Route ID in OSPF Process, follow these steps.

omnisecu.com.R1>enable
omnisecu.com.R1#configure terminal
omnisecu.com.R1(config)#router ospf 100
omnisecu.com.R1(config-router)#router-id 1.1.1.1
omnisecu.com.R1(config-router)#exit
omnisecu.com.R1(config)#exit
omnisecu.com.R1#

Related Tutorials
• Introduction to Link State Routing Protocols
• Introduction to Open Shortest Path First (OSPF) Protocol
• How to configure Open Shortest Path First (OSPF)
• What is OSPF Metric value Cost and OSPF default Cost Reference Bandwidth
• What is OSPF Router ID, OSPF Router ID Selection Algorithm and How to Configure OSPF Router ID
• What is OSPF Area, OSPF Hierarchical Network Design, and Advantages of OSPF Areas