Categories R&S

OSPF – Optimize convergence and scalability – Timers

Time to start the last series on OSPF, optimize convergence and scalability.

We will have a look first at the OSPF hello and dead timers.

 

 

Theory:

Default values for those timers depends of the OSPF network type configured.

Those values can be modified in order to improve OSPF convergence.

Hello and dead timers must match between neighbors to form an adjacency.

 

Requirements:

Make sure that the links between R4, R5 and R6 uses correct timers to declare neighbor down as soon as possible.

 

Diagram:

OSPF LSA filtering

Configuration and verification:

 

Let’s first the current status on those devices:

R4#sh ip ospf int Eth 1/0
Ethernet1/0 is up, line protocol is up
  Internet Address 10.10.2.4/24, Area 2, Attached via Network Statement
  Process ID 10, Router ID 4.4.4.4, Network Type BROADCAST, Cost: 1000
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5

R5#sh ip ospf int Eth 0/0
Ethernet0/0 is up, line protocol is up
  Internet Address 10.10.2.5/24, Area 2, Attached via Network Statement
  Process ID 10, Router ID 5.5.5.5, Network Type BROADCAST, Cost: 1000
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5

R6#sh ip ospf int Eth 0/0
Ethernet0/0 is up, line protocol is up
  Internet Address 10.10.2.6/24, Area 2, Attached via Network Statement
  Process ID 10, Router ID 6.6.6.6, Network Type BROADCAST, Cost: 1000
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5

 

So with those timers, what do we get if we shut down let’s say R5 interface:

R5(config)#int Eth 0/0
R5(config-if)#shut
* 10:23:02.562: %LINK-5-CHANGED: Interface Ethernet0/0, changed state to administratively down

R4#*10:23:38.323: %OSPF-5-ADJCHG: Process 10, Nbr 5.5.5.5 on Ethernet1/0 from FULL to DOWN, Neighbor Down: Dead timer expired
R6#*10:23:38.321: %OSPF-5-ADJCHG: Process 10, Nbr 5.5.5.5 on Ethernet0/0 from FULL to DOWN, Neighbor Down: Dead timer expired

 

More than 30s to declare the neighbor down, let’s change the timers to improve this convergence:

R4(config)#int Eth 1/0
R4(config-if)#ip ospf hello-interval 1

R4#sh ip ospf int Eth 1/0
Ethernet1/0 is up, line protocol is up
  Internet Address 10.10.2.4/24, Area 2, Attached via Network Statement
  Process ID 10, Router ID 4.4.4.4, Network Type BROADCAST, Cost: 1000
  Timer intervals configured, Hello 1, Dead 4, Wait 4, Retransmit 5

 

When changing only the hello interval, the dead interval is automatically adjust.

If we don’t adjust the timers on the other routers, the neighbor adjacency is not formed and we can see the following message with the “debug ip ospf hello” command:

*10:29:15.557: OSPF-10 HELLO Et1/0: Rcv hello from 5.5.5.5 area 2 10.10.2.5
*10:29:15.557: OSPF-10 HELLO Et1/0: Mismatched hello parameters from 10.10.2.5
*10:29:15.557: OSPF-10 HELLO Et1/0: Dead R 40 C 4, Hello R 10 C 1 Mask R 255.255.255.0 C 255.255.255.0

 

Let’s change the timers on R5 and R6:

R5(config)#int Eth 0/0
R5(config-if)#ip ospf hello-interval 1

R6(config)#int Eth 0/0
R6(config-if)#ip ospf hello-interval 1

 

We can now test again the convergence:

R5(config)#int Eth 0/0
R5(config-if)#shut
*Feb 24 12:02:02.722: %LINK-5-CHANGED: Interface Ethernet0/0, changed state to administratively down

R4#*12:02:03.833: %OSPF-5-ADJCHG: Process 10, Nbr 5.5.5.5 on Ethernet1/0 from FULL to DOWN, Neighbor Down: Dead timer expired
R6# *12:02:03.832: %OSPF-5-ADJCHG: Process 10, Nbr 5.5.5.5 on Ethernet0/0 from FULL to DOWN, Neighbor Down: Dead timer expired

 

As you can see the neighbor is declared dead much faster than with the default timers.

 

 

 

Thank you for reading.

 

 

OSPF – Optimize convergence and scalability – Timers