Friday, April 8, 2011

Faster OSPF Convergence using iSPF

According to this Cisco config guide, OSPF uses Dijkstra's SPF algorithm to compute the shortest path tree (SPT). During the computation of the SPT, the shortest path to each node is discovered. The topology tree is used to populate the routing table with routes to IP networks. When changes to a Type-1 or Type-2 link-state advertisement (LSA) occur in an area, the entire SPT is recomputed.

In many cases, the entire SPT need not be recomputed because most of the tree remains unchanged. Incremental SPF (iSPF) allows the system to recompute only the affected part of the tree. Recomputing only a portion of the tree rather than the entire tree results in faster OSPF convergence and saves CPU resources. Note that if the change to a Type-1 or Type-2 LSA occurs in the calculating router itself, then the full SPT is performed. Incremental SPF is scheduled in the same way as the full SPF. Routers enabled with incremental SPF and routers not enabled with incremental SPF can function in the same internetwork.

Given only pros and not cons, we should enable iSPF by default. iSPF can be easily enabled using ispf command under each router ospf process.
  1. router ospf 1
  2. ispf
  3. !
To verify:
  1. show ip ospf 1 | inc SPF
  2. ........
  3. Incremental-SPF enabled 
  4. .......

    2 comments:

    1. Ripped from http://routing-bits.com/2009/01/23/ospf-ispf/ ?

      ReplyDelete
    2. No, I read this from Cisco website:
      http://www.cisco.com/en/US/docs/ios/12_0s/feature/guide/ospfispf.html

      ReplyDelete