Akanksha Singh

Jul 4, 2021

6 min read

OSPF Protocol implementing Dijkstra’s Algorithm

OSPF is link state. That means it runs Dijkstra’s Shortest Path First (SPF) Algorithm, that is something that is common to all link state routing protocols which makes topology detail regarding network outside their area…

  • IP routing sending data packets from one network to another through routers. It is routers that examine destination IP address, determine next hop address to address a packet.
  • Remote router IP address of router used to reach that network outgoing interface. Populating routing table directly connected to subnets, static routing, default, dynamic routing.
  • Directly Connected Interface routes local to router (One or More) network subnets easily recognizable traffic directed to these network can be forwarded without any help from routing protocols.
  • Static Routing : Routes to destination manually entered by network administrators in router’s route table, don’t adjust to changes in the network.
  • Default Gateway : The router that hosts use to communicate with other hosts — remote networks.
  • Default Routing : Network having only one output interface, all the data going through a single exit. Instead of having many static routers connecting to remote networks, single output interface is configured to match all routes.
  • Dynamic Routing : Optimal data routing, enables routes to select paths according to real-time logical network changes. Routing protocol responsible for the creation, maintenance, update of a dynamic routing table. While in static routing all routing job have done manually by network administrator.

Comparing difference between Static and Dynamic Routing :

  1. Static routing is for small networks like small scale organization that has predicted number of users and static or minimum bandwidth usage, laborious tasks are set up. Here the roll of network admin is to troubleshoot manually at each failure hence it becomes a tedious task.
  2. Dynamic Routing used in case of large networks because of it’s capabilities like it keep changing and updating along with network topologies and are easier to maintain and supports network extension.
  3. Static Routing table are set by Network Administrator.
  4. Dynamic Routing Protocols dynamically discover network destinations. Continuously change network status updates between each other as broadcast or multicast-Routing Information Protocol (RIP). Enhanced Interior Gateway Routing Protocol (EIGRP), Open Shortest Path First (OSPF).
  1. Backbone Area : This interconnects all areas together and every area in OSPF must be connected via backbone area. Backbone areas are designed as a CORE area.
  2. Regular Area : These areas connects users and resource together. Regular areas are grouped based on geographical or functional purposes. One can reach other regular area using backbone area.
  • Stub area : Area that doesn’t allow external router to be propagated through. All router within the area must be configured as a stub to maintain neighbor relationship. Instead, external router are propagated by default route by ABR (Area Border Routers).
  • Totally Stub area : Area that does not allow external and summary routers instead propagating them as one default route. All router in the area must be configured as stub routers. ABR connected to area must be configured as totally stub.
  • Not-so-stubby area : Area that does not allow by default external routers to be propagated through, this rule can be bypass and some external routers can be propagated if necessary.
  • Totally not-so-stubby area : This is also same as Not-so-stubby area, but in addition it does not allow summary routers to be propagated through.
OSPF Architecture

🤔 Now the question comes, What is Dijkstra Algorithm? How OSPF uses Dijkstra behind the scene ?

Dijkstra algorithm is for finding the shortest paths between nodes in the graph. For the case of directed weighted graphs we conclude the minimum path by using this particular algorithm. As I have mentioned in above discussion about tables where OSPF stores information. Topology table can easily be read to list of all the network and then one-by-one Dijkstra algorithm calculates the best path to each of those destinations.

Conclusion :

👉 Visit the following blog titled “OSPF Data Overview” from learncisco site where they have motioned the OSPF metrics and paranoid update clearly.

(: — )

Thanks for reading. Hope this blog have given you some valuable inputs!!