Showing results for 
Search instead for 
Did you mean: 
Join Customer Connection to register!

OSPF - Router ID

Hi All,

I am not sure if I should be posting here but I could not find an answer anywhere. I am currently studying CCNA3 Chapter 5 and I cannot get my head around something regarding the OSPF DR/DBR election process. The course teaches us that the election preference follows the order:

  1. Priority
  2. Manually Configured Router ID
  3. Highest Loopback Address
  4. Highest IPv4 Address

However, in the attached figure (question_4.1 + question_4.2), I cannot understand why R2 becomes the DBR for segment A instead of R3? R3 has a manually configured router ID but R2's loopback interface seems to be given priority. Shouldn't R3 become the DBR since it has a manually configured router ID?

The only theory I can come up with is that manually configured router IDs are only taken into account if all routers in a segment are configured. But this does not seem right.

Any help appreciated :-)


Cisco Freak

R1 router will become DR for the segment A because of the highest priority value 128.

R2 and R2 will compete for BDR. They both the have priority value 1. Next is the router-id comparison

R3 has the router-id

R2 doesn't have the router-id hard-coded. So it will elect loopback IP as the router-id which is is better than So R2 will win the election and it will become the BDR.


Thanks CF, that makes sense. Mistery solved! 



Router without router id cant join ospf domain. If router id is not set than it'll be picked by ospf process from one of the routers' interface and loopbacks will be searched first for router's ip, and if has no loopbacks then highest ip will be picked from active interfaces.

Algorithm you posted might be right but unfortunately it hides what is really going on.

Jon Marshall
Hall of Fame Guru

CF has explained how it works but I think the confusion is coming because you are assuming that each router knows how the other routers selected their router IDs.

The selection of the router ID is local to the router itself.

R2 has no idea the router ID used by R3 came from a manually configured router ID and it doesn't need to know.

There is nothing in the election that says to other routers in the same segment which interface was used to pick the router ID so all routers simply look at the IP address in the LSAs they receive.


Hi Jon,


Thanks for the response! It is a lot clearer when you put it this way. 


Thank you,