OSPF adjacency formation involves several states a router goes through before it becomes fully adjacent with a neighbor. These state changes are defined in the OSPF RFC 2328, section 10.1. Here are the seven stages:
OSPF Adjacency States
Stage | Description |
---|---|
Down | This is the initial state where no information has been exchanged between the neighbors. No hellos have been received. |
Attempt | (For NBMA networks) The router is trying to contact neighbors and has not received any Hello packets. |
Init | A Hello packet has been received from a neighbor, but the receiving router has not yet seen its own Router ID in the received hello. |
2-Way | The router has seen its own Router ID in a received Hello, meaning that bi-directional communication has been established. |
ExStart | The routers negotiate who will send the Database Description (DBD) packets first. |
Exchange | The routers exchange DBD packets, which describe the contents of their link-state database. |
Loading | The routers send Link State Request (LSR) packets to request the most recent information about the network from their neighbors. |
Full | The routers are fully synchronized and have the same link-state databases, having formed an adjacency. |
Understanding OSPF Adjacency Formation
- OSPF uses hello packets to discover neighbors and build adjacencies.
- The state changes show the progression from initial discovery to fully synchronized databases.
- Not all states are always seen, especially if the adjacency is established quickly on a point-to-point link.
- The Attempt state is only seen on Non-Broadcast Multi-Access (NBMA) networks.
- Full adjacency means that all link-state information is shared, leading to a consistent routing topology.