Figure 1 shows the reference topology.
Use the show ip ospf neighbor command to verify that the router has formed an adjacency with its neighboring routers. If the router ID of the neighboring router is not displayed, or if it does not show as being in a state of FULL, the two routers have not formed an OSPF adjacency.
If two routers do not establish adjacency, link-state information is not exchanged. Incomplete LSDBs can cause inaccurate SPF trees and routing tables. Routes to destination networks may not exist, or may not be the most optimum path.
Figure 2 displays the neighbor adjacency of R1. For each neighbor, this command displays the following output:
- Neighbor ID - The router ID of the neighboring router.
- Pri - The OSPF priority of the interface. This value is used in the DR and BDR election.
- State - The OSPF state of the interface. FULL state means that the router and its neighbor have identical OSPF LSDBs. On multiaccess networks, such as Ethernet, two routers that are adjacent may have their states displayed as 2WAY. The dash indicates that no DR or BDR is required because of the network type.
- Dead Time - The amount of time remaining that the router waits to receive an OSPF Hello packet from the neighbor before declaring the neighbor down. This value is reset when the interface receives a Hello packet.
- Address - The IPv4 address of the neighbor’s interface to which this router is directly connected.
- Interface - The interface on which this router has formed adjacency with the neighbor.
Use the Syntax Checker in Figure 3 to verify the R2 and R3 neighbors using the show ip ospf neighbor command.
Two routers may not form an OSPF adjacency if:
- The subnet masks do not match, causing the routers to be on separate networks.
- OSPF Hello or Dead Timers do not match.
- OSPF Network Types do not match.
- There is a missing or incorrect OSPF network command.