OSPF routers must agree on several interface and protocol parameters before they become fully adjacent. Effective OSPF adjacency troubleshooting starts with the neighbour state, verifies basic IP connectivity, and then checks OSPF settings in a fixed order.
This guide uses Cisco IOS commands and a practical two-router lab. It assumes that you understand basic routing and subnetting; learners who need that foundation can begin with the CCNA course.
What Is an OSPF Adjacency Problem?
An OSPF adjacency problem occurs when two expected neighbours cannot reach the FULL state or repeatedly move between states. The current neighbour state usually identifies which part of the adjacency process is failing.
OSPF neighbours discover each other with Hello packets. They then select master and slave roles, exchange database descriptions, request missing link-state advertisements and synchronise their link-state databases.
Diagram in words:
R1 Gi0/0 10.10.12.1/30 -------- 10.10.12.2/30 Gi0/0 R2
OSPF area 0, Ethernet link
Expected progression:
DOWN -> INIT -> 2-WAY -> EXSTART -> EXCHANGE -> LOADING -> FULLNot every neighbour must become FULL on a broadcast multi-access segment. Two DROTHER routers normally remain in the 2-WAY state with each other while forming FULL adjacencies with the designated router and backup designated router.
Which OSPF Neighbour State Should You Check First?
Start with show ip ospf neighbor and note the state, neighbour router ID, dead timer and local interface. A missing neighbour entry points toward discovery or configuration problems, while a neighbour stuck in a specific state narrows the investigation.
R1# show ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
2.2.2.2 1 EXSTART/DR 00:00:34 10.10.12.2 GigabitEthernet0/0In this example, R1 receives Hellos from R2, but database exchange is not progressing beyond EXSTART.
| State | Meaning | Common causes to investigate |
|---|---|---|
| No entry | No valid Hello received | OSPF not enabled, passive interface, link failure, ACL or wrong subnet |
| INIT | Hello received, but local router ID is not listed in it | One-way communication, filtering or Layer 2 problem |
| 2-WAY | Bidirectional Hello communication exists | Normal between DROTHERs, or investigate DR election and network type |
| EXSTART | Master/slave negotiation is incomplete | MTU mismatch, duplicate router ID or unstable link |
| EXCHANGE | Database description packets are being exchanged | MTU, packet loss or malformed LSA problems |
| LOADING | Router is requesting missing LSAs | Missing responses, packet loss or database inconsistency |
| FULL | Databases are synchronised | Adjacency is healthy; investigate route selection instead |
Use the detailed form when you need timers, retransmissions and neighbour options:
R1# show ip ospf neighbor detailWhat Is the Correct OSPF Troubleshooting Order?
Check the physical and IP layers before changing OSPF. Then verify protocol activation, Hello compatibility, authentication, network type, MTU and router IDs in that order.
Step 1: Verify Interface and IP Connectivity
Both connected interfaces must be operational and addressed in the expected subnet. Begin with concise interface information and a direct ping.
R1# show ip interface brief
R1# show interfaces GigabitEthernet0/0
R1# ping 10.10.12.2 source 10.10.12.1Expected interface status:
GigabitEthernet0/0 10.10.12.1 YES manual up upIf the interface is administratively down, enable it:
R1(config)# interface GigabitEthernet0/0
R1(config-if)# no shutdownA successful ping does not prove that OSPF works because ICMP and OSPF are different IP protocols. However, a failed directly connected ping should be resolved before investigating neighbour negotiation.
Check the subnet masks on both routers. On Ethernet, an incorrect mask can prevent neighbour formation even when selected addresses appear to be in the same broad address range.
Step 2: Confirm That OSPF Is Enabled on the Interface
Verify that the interface participates in the intended OSPF process and area. The local process ID does not have to match between routers, but the area ID on the shared link must match.
R1# show ip ospf interface brief
R1# show ip protocols
R1# show running-config | section router ospfExample network-statement configuration:
R1(config)# router ospf 10
R1(config-router)# network 10.10.12.0 0.0.0.3 area 0Alternatively, OSPF can be enabled directly on an interface:
R1(config)# interface GigabitEthernet0/0
R1(config-if)# ip ospf 10 area 0A common mistake is an incorrect wildcard mask that does not select the interface. Remember that a network statement identifies local interfaces; it does not directly advertise a remote network.
Step 3: Check for a Passive Interface
A passive OSPF interface advertises its connected network but does not send or receive OSPF Hellos. Remove the passive setting only on interfaces where an adjacency is required.
R1# show ip protocolsLook for the passive interface list. If passive-interface default is configured, explicitly enable neighbour formation on the transit interface:
R1(config)# router ospf 10
R1(config-router)# no passive-interface GigabitEthernet0/0Do not disable passive mode on user-facing interfaces without a design reason. Passive interfaces reduce unnecessary protocol exposure.
Step 4: Compare Areas, Timers and OSPF Options
Neighbours must agree on important Hello parameters, including the area, Hello and dead intervals, authentication and stub-area options. show ip ospf interface presents most of these values in one place.
R1# show ip ospf interface GigabitEthernet0/0
R2# show ip ospf interface GigabitEthernet0/0Typical Ethernet output includes:
Process ID 10, Router ID 1.1.1.1, Network Type BROADCAST
Area 0, Cost 1
Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5If R1 uses Hello 10 and dead 40 while R2 uses Hello 5 and dead 20, make them consistent:
R2(config)# interface GigabitEthernet0/0
R2(config-if)# ip ospf hello-interval 10
R2(config-if)# ip ospf dead-interval 40Also verify that both interfaces use the same area type. For example, one router configured with area 10 stub cannot form an adjacency with a neighbour that treats area 10 as a normal area.
Step 5: Verify OSPF Authentication
Authentication type and credentials must match on both ends. A key ID mismatch, password mismatch or authentication enabled on only one router prevents adjacency formation.
Example message-digest authentication:
R1(config)# interface GigabitEthernet0/0
R1(config-if)# ip ospf authentication message-digest
R1(config-if)# ip ospf message-digest-key 1 md5 LABKEYApply an equivalent configuration to R2. Use show ip ospf interface to confirm the authentication type, and inspect the running configuration for the key ID. Cisco IOS normally hides or obscures secrets depending on platform and configuration, so compare them carefully rather than relying only on displayed text.
Step 6: Check OSPF Network Types and DR Behaviour
Network type controls Hello defaults, neighbour discovery and DR/BDR election. Both ends should use a compatible type that matches the underlying topology.
R1# show ip ospf interface GigabitEthernet0/0 | include Network TypeFor a direct Ethernet link, point-to-point OSPF can simplify operation by removing DR and BDR election:
R1(config)# interface GigabitEthernet0/0
R1(config-if)# ip ospf network point-to-pointConfigure the same type on R2. On a shared Ethernet LAN, retain the broadcast type unless the network design requires something else.
If two routers on a multi-access network are both DROTHERs, the 2-WAY state between them is expected. Confirm their adjacency with the DR and BDR before treating 2-WAY as a fault.
Step 7: Investigate EXSTART and EXCHANGE MTU Problems
A neighbour repeatedly stuck in EXSTART or EXCHANGE often indicates an interface MTU mismatch. Compare MTU values on both sides instead of immediately restarting OSPF.
R1# show interfaces GigabitEthernet0/0 | include MTU
R2# show interfaces GigabitEthernet0/0 | include MTUExample mismatch:
R1: MTU 1500 bytes
R2: MTU 1400 bytesThe preferred fix is to make the Layer 3 MTU consistent with the actual path:
R2(config)# interface GigabitEthernet0/0
R2(config-if)# mtu 1500Some platforms and designs use the following workaround:
R2(config-if)# ip ospf mtu-ignoreTreat ip ospf mtu-ignore as a controlled exception, not the first fix. Ignoring the OSPF MTU check can allow adjacency formation while larger production packets still fail elsewhere on the path.
Step 8: Check for Duplicate Router IDs
Every OSPF router must have a unique router ID. Duplicate IDs can cause unstable adjacencies, rejected relationships or unexpected link-state database behaviour.
R1# show ip ospf | include Router ID
R2# show ip ospf | include Router IDConfigure explicit, unique IDs for predictable operation:
R1(config)# router ospf 10
R1(config-router)# router-id 1.1.1.1
R2(config)# router ospf 20
R2(config-router)# router-id 2.2.2.2Changing the configured router ID does not always change the active OSPF router ID immediately. A process restart may be required:
R2# clear ip ospf process
Reset ALL OSPF processes? [no]: yesThis command removes current OSPF adjacencies and routes temporarily. Use it during an approved change window on production equipment.
Step 9: Inspect ACLs, Firewalls and Multicast Reachability
OSPF runs directly over IP protocol 89; it does not use TCP or UDP ports. Infrastructure ACLs, control-plane policies, virtual firewalls or provider networks must permit OSPF traffic between neighbours.
OSPF commonly uses multicast addresses 224.0.0.5 for all OSPF routers and 224.0.0.6 for DR/BDR communication. Review interface ACLs and counters:
R1# show ip interface GigabitEthernet0/0
R1# show access-lists
R1# show ip traffic | include OSPFAlso check VLAN membership, trunk forwarding, port channels and intermediate security devices. An INIT state strongly suggests that communication may work in only one direction.
How Do You Troubleshoot a Practical OSPF Lab Failure?
Collect evidence from both routers, compare values side by side and change one confirmed mismatch at a time. This prevents several simultaneous changes from hiding the original cause.
Assume R1 remains in EXSTART with R2. The following evidence is collected:
R1# show ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
2.2.2.2 1 EXSTART/DR 00:00:37 10.10.12.2 Gi0/0
R1# show interfaces gi0/0 | include MTU
MTU 1500 bytes
R2# show interfaces gi0/0 | include MTU
MTU 1400 bytesThe neighbour is visible, so interface addressing, Hello reception and area compatibility are probably working. EXSTART plus the confirmed MTU difference identifies the most likely cause.
After correcting R2 to MTU 1500, verify recovery:
R1# show ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
2.2.2.2 1 FULL/DR 00:00:38 10.10.12.2 Gi0/0Then confirm routes and database information:
R1# show ip route ospf
R1# show ip ospf database
R1# show ip ospf interface briefFULL proves database synchronisation with that neighbour. It does not prove that every expected route exists, so route advertisement, filtering, summarisation and path selection may require separate investigation. Advanced routing diagnosis is practised in the CCNP Enterprise course.
When Should You Use OSPF Debug Commands?
Use debug commands only after targeted show commands fail to identify the problem. Debugging can generate significant output and CPU load, especially on busy production routers.
Useful commands include:
R1# debug ip ospf adj
R1# debug ip ospf hello
R1# show loggingStop debugging immediately after collecting the required evidence:
R1# undebug allPrefer terminal monitoring only during a controlled session. For repeated checks across many routers, structured command collection can be automated; see network automation basics with Python and Netmiko.
OSPF Adjacency Troubleshooting Checklist
A reliable checklist reduces guesswork and unnecessary process resets. Record the output before and after each configuration change.
- Confirm both interfaces are up/up.
- Verify directly connected IP addresses and subnet masks.
- Confirm OSPF is enabled on the correct interfaces.
- Check that neither transit interface is unintentionally passive.
- Compare area IDs and area types.
- Compare Hello and dead intervals.
- Verify authentication type, key ID and secret.
- Compare OSPF network types and DR roles.
- Check interface MTU values.
- Confirm unique router IDs.
- Inspect ACLs, firewalls, VLANs and multicast forwarding.
- Read the neighbour state again and verify OSPF routes.
Frequently Asked Questions
Why is an OSPF neighbour stuck in INIT?
INIT means the router receives a neighbour's Hello but does not see its own router ID inside that Hello. Check for one-way ACL filtering, multicast problems, VLAN faults and interface errors.
Is OSPF 2-WAY always a problem?
No. On broadcast networks, two DROTHER routers normally remain 2-WAY with each other and become FULL with the DR and BDR. On a point-to-point link, persistent 2-WAY requires investigation.
Do OSPF process IDs need to match?
No. OSPF process IDs are locally significant on Cisco IOS, so R1 can use process 10 while R2 uses process 20. The connected interfaces must still agree on the area and required neighbour parameters.
Why does OSPF get stuck in EXSTART?
An MTU mismatch is a common cause, but duplicate router IDs, packet loss and negotiation problems are also possible. Compare MTU and router IDs on both routers before restarting the process.
Can ping work while OSPF adjacency fails?
Yes. Ping uses ICMP, while OSPF uses IP protocol 89 and specific multicast communication. Authentication, timers, area settings or ACLs can break OSPF even when ICMP succeeds.
What command safely confirms an OSPF adjacency?
Use show ip ospf neighbor and verify that the expected neighbour is FULL where a full adjacency is required. Also check show ip route ospf and show ip ospf database because FULL alone does not confirm every expected route.
Summary
OSPF adjacency troubleshooting should follow the protocol state instead of relying on random configuration changes. Start with interfaces and IP connectivity, then verify OSPF activation, passive settings, areas, timers, authentication, network types, MTU, router IDs and packet filtering.
For guided routing labs, troubleshooting practice and current batch or enquiry details, visit the CCNP Enterprise course.
Reviewed by Network Rhinos networking trainers.
