OSPF in 100 Seconds

Open Shortest Path First Thumbnail image

OSPF, it is an open source interior gateway protocol, which is used to route traffic within the autonomous systems.

It works on the “Let every router know about every network” principle

And to do so, Router share their network information in the LSA Packets

These LSAs are stored in the database known as Link State Database, LSDB

and the goal of OSPF is to have the same LSDB in all of the routers.

How it works is

Each Router have a router ID, which is configured either manually or automatically.… and sends out a hello packet to nearby router,.

Other router checks the requirement and if everything is good, sends out an hello packet as well to become the neighbours.

Now, the routers need to exchange the information, but.. in a huge network – if every devices talk at the same time… ex cessive traffic is generated.

Now the routers need to exchange the information, but, in a large network – when a link gets changed.. then this update is announced by every routers, and a lot of OSPF traffic is generated.

So, the routers elect a Designated Router or (DR) as well as backup DR, which will make the annoucement when the link is changed, and.. other routers will ignore the update unless it’s from the Designated Router.

This significantly reduces the OSPF traffic,

The DR selection is done based on the OSPF priority order / or Router ID (if the priority is a tie)

After election, routers share the list of their LSA with each other, known as database description or DBD

Routers look over the DBD and request for any information that it doesn’t have using a Link State Request (LSR)

The response is sent out using a LInk State Update (LSU) packet.

Link State Acknowledgement (LSAck)

At this point, routing information is exchanged, and all routers have a same LSDB information..

But how does a router selects route using this database?

In short.. Routes are selected on the basis of link cost.

The cost is set for different types of links:

And, cost is pre-calculated for each route..

For example: To send a packet from Router A to Router E, the path with the least cost.. is the preferred option for routing.

For the management aspect.. in a very large network – the LSDB of each router could have thousands of items.. with even more number of routes.

And, finding a specific route in a huge list takes time.. which makes it slow.

To solve this… the network can be broken down into multiple areas,

The router within the area, maintains a link state database of only that area…and Inter-area routing is managed by area border routers.

This reduced LSDB and Routes increases the network performance & scalibility.

Setting up OSPF in a router is also a piece of cake

Just type..

Provide the list of all directly connected of that router with their wildcard mask.

And you’re done. Give it some moment.. and OSPF will work it’s magic

This is all for OSPF, see you in the next one.

Tags:

Leave a Reply

Your email address will not be published. Required fields are marked *

Light