Logging OSPF Adjacency Changes
Problem
You want to monitor OSPF adjacency state changes to ensure network stability.
Solution
The log-adjacency-changes configuration command instructs the router to create a log message whenever two OSPF routers establish or break their adjacency relationship:
Router2#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router2(config)#router ospfRouter2(config-router)#12log-adjacency-changesRouter2(config-router)#exitRouter2(config)#endRouter2#
Discussion
No routes are exchanged between routers if they lose their adjacency relationship. Every time this relationship is lost, the corresponding routes are removed, and every router in the area must be updated with the new network topology. This can be quite disruptive to a network. So it can be extremely useful to log these changes for troubleshooting, as well as for reconstructing serious problems that occurred in the past. We recommend using this option.
Here are some example log messages. The first message shows that the adjacency has been lost due to an expired timer. This means that this router has not heard its neighbor’s regularly scheduled “hello” messages recently, so it needs to delete its routes. A few minutes later, the neighbor has come back and reestablished its adjacency:
Oct 14 09:54:13: %OSPF-5-ADJCHG: Process 12, Nbr 172.25.25.1 on Serial0/0 from FULL to DOWN, Neighbor Down: Dead timer expired Oct 14 09:57:43: %OSPF-5-ADJCHG: Process 12, Nbr 172.25.25.1 on ...Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access