This is a completely not fun, dry, and hard to remember list of how two routers become neighbors / form an adjacency in order of what happens. I am typing it here purely for future reference, so if you are looking for an intriguing perspective on something, probably want to look read another post:
- Init – First Hello received from remote router
- 2-Way – Each router has received a Hello containing it’s own RID, indicating bi-directional communication, getting it’s own RID from the remote router as a sort of receipt that a Hello was received by the remote router from the local
- Exstart – Following the DR / BDR election, the router with the highest RID will begin the exchange of the initial sequence number and increment during this stage
- Exchange – Database Descriptor (DBD) packets are exchanged, which contain LSA headers only to describe the senders LS Database, so the sequence number can be compared to the local sequence number, and updated by the DR if necessary
- Loading – Routers send Link State Requests (LSR) packets to the now almost neighbors
- Full – Routers are synched, adjacency is formed
These states can be found with “show ip ospf nei”, the ‘State’ being the first value in the brackets, the second being the ‘Role’ of the router. Here are a listing of the roles:
DR – Designated Router via the initial election process of OSPF speaking routers, once elected it stays DR until a reload is done or ‘clear ip ospf process’, acts as the “Master” of OSPF updates in terms of maintaining the most current sequence number / LS Database and updating other OSPF enabled routers via Multicast to 126.96.36.199 (All OSPF routers address) if it receives an update with a higher sequence number than it currently has, elected via highest RID which is takes precedence in the follow order: “router-id” command, highest IP Addy on loopback interface, highest IP addy on physical interface – DOES NOT NEED TO BE OSPF ENABLED INTERFACE FOR IP TO BE USED AS RID FOR OSPF ELECTION.
BDR – Backup Designated Router, keeps an up to date routing table, does not perform any functions of the DR but does listen on the “All Designated Routers” multicast address of 188.8.131.52 for LS Database updates. Only the DR and BDR listen to this IP for Link State updates.
DROther – Non-DR / BDR routers
**Interface priority will win the DR / BDR election before IP addy’s are considered, so raising this priority can ‘rig’ election to either ensure a router is elected, or if it is changed to priority 0 the router will not participate in election.**
I will need to add or edit this, or include some more details in an upcoming post on OSPF fundamentals, but wanted to get this posted now so I can move onto new topics in my next post. Writing a conclusive article on the basics of OSPF that is under 30 pages seems like it may be a difficult task, so I’ll probably just pick the more important topics that will be needed for test time, as I’d rather be able to answer questions on theory than burn it into my brain, and save the brain for labbing and understanding configuration and troubleshooting 🙂