FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
knaveenkumar
Staff
Staff
Article Id 241311
Description This article outlines steps to troubleshoot a duplicate router ID during the process of forming OSPF neighbors in FortiGate and FortiOS.
Scope

FortiGate.

Solution

edit.PNG

 

In the above diagram, Router 1's router-id is 1.1.1.1, and Router 2's router-id is 2.2.2.2. 

 

Note:

The router ID will be selected based on the manually configured router ID. If a manual router ID is not configured, then the highest IP address on the loopback interface will be used. If the loopback interface is not present, the highest physical active interface IP will be preferred as the OSPF router ID.

 

In OSPF, the router-id should be unique on both devices to form the OSPF neighborship.

 

to check the ospf neighbor, run the following commands:

 

get router info ospf neighbor
OSPF process 0, VRF 0:
Neighbor ID Pri State Dead Time Address Interface
10.0.5.231 1 Full/DR 00:00:38 10.5.21.231 port1

 

Run the debug commands to check what router id being sent and received.

 

diagnose debug disable
diagnose debug reset
diagnose debug console timestamp enable
diagnose ip router ospf all enable
diagnose ip router ospf level info
diagnose debug enable

 

After few minutes, disable the debugs with the following commands.

 

diagnose debug disable
diagnose debug reset

 

Debug output:


neutron-esx34 # OSPF: LSA[Refresh]: timer expired
OSPF: IFSM[port1:10.5.27.232]: Hello timer expire
OSPF: SEND[Hello]: To 224.0.0.5 via port1:10.5.27.232, length 48 <----- Sending hello out via port1:10.5.27.232.
OSPF: -----------------------------------------------------
OSPF: Header
OSPF: Version 2
OSPF: Type 1 (Hello)
OSPF: Packet Len 48
OSPF: Router ID 1.1.1.1 <----- The sending router-id is 1.1.1.1.
OSPF: Area ID 0.0.0.0
OSPF: Checksum 0xd9c6
OSPF: AuType 0
OSPF: Hello
OSPF: NetworkMask 255.255.240.0
OSPF: HelloInterval 10
OSPF: Options 0x2 (*|-|-|-|-|-|E|-)
OSPF: RtrPriority 0
OSPF: RtrDeadInterval 40
OSPF: DRouter 10.5.21.231
OSPF: BDRouter 0.0.0.0
OSPF: # Neighbors 1
OSPF: Neighbor 10.0.5.231
OSPF: -----------------------------------------------------
OSPF: RECV[Hello]: From 1.1.1.1 via port1:10.5.27.232 (10.5.28.246 -> 224.0.0.5) <--- receiving hello via port1:10.5.27.232
OSPF: -----------------------------------------------------
OSPF: Header
OSPF: Version 2
OSPF: Type 1 (Hello)
OSPF: Packet Len 48
OSPF: Router ID 1.1.1.1 <----- While receiving router ID 1.1.1.1.
OSPF: Area ID 0.0.0.0
OSPF: Checksum 0xd9c6
OSPF: AuType 0
OSPF: Hello
OSPF: NetworkMask 255.255.240.0
OSPF: HelloInterval 10
OSPF: Options 0x2 (*|-|-|-|-|-|E|-)
OSPF: RtrPriority 0
OSPF: RtrDeadInterval 40
OSPF: DRouter 10.5.21.231
OSPF: BDRouter 0.0.0.0
OSPF: # Neighbors 1
OSPF: Neighbor 10.0.5.231
OSPF: -----------------------------------------------------
OSPF: RECV[Hello]: duplicate router-id 1.1.1.1 detected on port1:10.5.27.232 <--- duplicate router-ID
OSPF: LSA[MaxAge]: Maxage walker finished (0.000000 sec)


After correcting router2's router ID as 2.2.2.2, the OSPF neighborship goes up successfully.


get router info ospf neighborship is up
OSPF process 0, VRF 0:
Neighbor ID Pri State Dead Time Address Interface
10.0.5.231 1 Full/DR 00:00:35 10.5.21.231 port1
1.1.1.1 0 Full/DROther 00:00:35 10.5.28.246 port1 <----- R1 router id 1.1.1.1.

 

get router info ospf neighbor
OSPF process 0, VRF 0:
Neighbor ID Pri State Dead Time Address Interface
10.0.5.231 1 Full/DR 00:00:38 10.5.21.231 port1
2.2.2.2 1 Full/Backup 00:00:33 10.5.27.232 port1 <----- R2 router-id 2.2.2.2.

 

Note:

  • Routers in the different Areas can have duplicate Router IDs.
  • The router in ASBRs must have a unique Router ID.