Introduction to OSPF

OSPF is a link-state routing protocol and it’s one of the routing protocols you need to understand if you want to do the Cisco CCNA, CCNP or CCIE R&S exam(s). In this lesson I’ll explain the basics of OSPF to you and you will learn how and why it works.

Continue reading


OSPF uses a LSDB (link state database) and fills this with LSAs (link state advertisement). Instead of using 1 LSA packet OSPF has many different types of LSAs and in this tutorial I’m going to show all of them to you. Let’s start with an overview:

Continue reading

OSPF Router ID

Each OSPF router selects a router ID (RID) that has to be unique on your network. OSPF stores the topology of the network in its LSDB (Link State Database) and each router is identified with its unique router ID , if you have duplicate router IDs then you will run into reachability issues.

Continue reading

OSPF Passive Interface

When you use the network command in OSPF, two things will happen:

  • All interfaces that have a network that falls within the range of the network command will be advertised in OSPF.
  • OSPF hello packets are sent on these interfaces.

Continue reading

OSPF Next Hop IP Address with different Network Types

OSPF will use different IP addresses for the next hop depending on the network type that you use. This can be confusing when you try to configure OSPF on top of a frame-relay network. In this short lesson I want to show you the difference between the next hop IP address and the OSPF network type that we use.

Continue reading

OSPF Hello and Dead Interval

OSPF uses hello packets and two timers to check if a neighbor is still alive or not:

  • Hello interval: this defines how often we send the hello packet.
  • Dead interval:  this defines how long we should wait for hello packets before we declare the neighbor dead.

Continue reading

How to configure OSPF Summarization

If you are studying OSPF you will learn that OSPF uses LSA type 3 for inter-area routers and LSA type 5 for external prefixes that are redistributed into OSPF.

OSPF can do summarization but it’s impossible to summarize within an area. This means we have to configure summarization on an ABR or ASBR. OSPF can only summarize our LSA type 3 and 5.

Continue reading

How to configure OSPF Virtual Link

If you studied Cisco’s CCNA you have learned that when you use OSPF all the areas have to be directly connected to the backbone area. Is this really true? Areas have to be connected to the backbone area but if they aren’t we can fix it with a virtual link.Look at the following example:

Continue reading

OSPF ABR Type 3 LSA Filtering on Cisco IOS

OSPF uses LSA type 3 for inter-area prefixes and if you want, you can filter these between OSPF areas. Since you can only filter between areas you’ll have to configure this on the ABR. Filtering is possible inbound or outbound an area by using the area filter-list command.

Continue reading

OSPF Path Selection

As you might have learned in CCNA or CCNP, OSPF will use cost as the metric to choose the shortest path for each destination, this is true but it’s not entirely correct. OSPF will first look at the “type of path” to make a decision and secondly look at the metric. This is the prefered path list that OSPF uses:

Continue reading

OSPF Distribute-List Filtering

OSPF supports a number of methods to filter routes but it is more restrictive compared to distance vector routing protocols like RIP or EIGRP.

As a link-state routing protocol OSPF uses LSAs to build its LSDB (Link State Database). Routers will run the SPF algorithm to find the shortest path to each destination, the topology in the LSDB has to be the same on all routers or SPF will fail.

Continue reading

OSPFv3 for IPv4 Configuration

OSPF has seen quite some changes since it was introduced somewhere in the 1980s.

The first time it was documented was in 1989 in RFC 1131. Some improvements were made in OSPF version 2, first announced in RFC 1247, updated by RFC 1583, 2178 and 2328.

Continue reading