6.3 OSPF Operation Overview

STEP ONE: ESTABLISH ADJACENCIES

When neighbor relationships are formed in OSPF, it is because an OSPF router is listening to a well-known multicast address (224.0.0.5) for hello packets.

Hello packets contain the following criteria that each router must validate and agree to when these packets are exchanged:

  • Area ID
  • Hello and Dead Intervals
  • Authentication, if used
  • Stub Area Flag, if any special area types are used

STEP TWO: BUILD THE LINK-STATE DATABASE

Once everyone has joined, each router floods information about its connected routes to the rest of the neighbors in the area (LSAs) to build the Link State Database.

Information communicated in Link State Advertisements (LSAs) include the following:

  • Router ID
  • Interface
  • IP Address
  • Mask
  • Subnet
  • A list of all routers reachable on an interface

STEP THREE: RUN BEST PATH (SPF) ALGORITHM

Once link state databases are built, each router runs the Dijkstra algorithm to build an SPF tree, which essentially builds a topology map where the router is the root of the tree with a view toward every remote network advertised by the routers participating in the OSPF process.

Once each router has its SPF tree, it inserts only the best routes into its routing table. The paths with the smallest cost to reach a destination are candidates for the routing table..