Description | This article describes how to troubleshoot OSPF neighborship between firewalls/routers. |
Scope | FortiGate. |
Solution |
Topology:
10.10.10.1 --> Router id: 1.1.1.1. 10.10.10.2 --> Router id: 2.2.2.2.
The 2-way state means a bi-directional communication has been established between the routers. At this point, the routers perform DR and BDR elections.
Note: DR and BDR election happens for each segment.
Note: Sometimes, MTU does match on both sides but still, the neighbor-ship is stuck in the Exstart state because DBD/LSU packets are expiring and they are unable to reach the other side. This could be caused by an L2 switch or L2-WAN device (MPLS) which is placed between OSPF routers and does not forward packets at this MTU.
FortiGate can only send and receive 5 Database Descriptors (DD) packets at a given point of time in a queue for all interfaces trying to form a neighbor-ship. If multiple OSPF interfaces are negotiating at the same time, it will take some time to form the neighbor-ship between routers.
Note: If OSPF interfaces are stuck in ExStart/Exchange state for some reason and the OSPF process queue is 5/5, then other OSPF interfaces will not be able to form neighbor-ship to 'Full' as well.
Some user commands:
diag sniffer packet any “proto 89” 6 0 l diag sniffer packet any “ host 224.0.0.5” 6 0 l get router info ospf neighbor get router info ospf interface
In case of configuration with more OSPF peers, to filter the sniffer for specific peers, commands below can be used :
diag sniffer packet any "(host 10.10.10.1 and proto 89) or (proto 89 and host 10.10.10.2)" 6 0 l
This sniffer will capture all the traffic from 10.10.10.1 and protocol number 89 or traffic from 10.10.10.2 and protocol number 89. For OSPF always the source is unicast address, and the destination is multicast.
The OSPF debug can show error messages as well if the adjacency is not forming.
diagnose debug disable diagnose ip router ospf all enable / disable diagnose debug enable
The sample debug output below shows that the OSPF Hello received on the 'ospftest' interface did not contain the correct OSPF area ID. OSPF: RECV[Hello]: From 10.90.32.1 via ospftest:10.90.32.2: Invalid Area ID 0.0.0.0 OSPF: IFSM[ospftest:10.90.32.2]: Hello timer expire OSPF: SEND[Hello]: To 224.0.0.5 via ospftest:10.90.32.2, length 44 OSPF: ----------------------------------------------------- OSPF: Header OSPF: Version 2 OSPF: Type 1 (Hello) OSPF: Packet Len 44 OSPF: Router ID 10.90.32.2 OSPF: Area ID 0.0.0.1 OSPF: Checksum 0xd142 OSPF: AuType 0 OSPF: Hello OSPF: NetworkMask 255.255.255.255 OSPF: HelloInterval 10 OSPF: Options 0x2 (*|-|-|-|-|-|E|-) OSPF: RtrPriority 1 OSPF: RtrDeadInterval 40 OSPF: DRouter 0.0.0.0 OSPF: BDRouter 0.0.0.0 OSPF: # Neighbors 0 OSPF: ----------------------------------------------------- |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2024 Fortinet, Inc. All Rights Reserved.