Pcornel
Browse topics
Options
Recent
Favorites
Networking · Technical reference

OSPF Protocol Reference

Direct answer

OSPF is a link-state routing protocol: routers form adjacencies, exchange a description of every link in their area, and each computes the shortest paths itself. The topics here cover its packets, states and LSA types.

When to use this

Start here when a neighbour does not come up, a route is missing or takes an unexpected path, or to read OSPF in a capture.

First 30 seconds

1. show ip ospf neighbor — is the neighbour listed, and Full?

2. Not listed → show ip ospf interface <interface> on both ends: area, timers, network type, passive?

3. Stuck in ExStart/Exchange → MTU mismatch.

4. Full but route missing → show ip ospf database: is the LSA there? Filtered at an area border?

5. Unexpected path → compare interface costs along both paths.

Operational verification

interface in OSPF, not passive → hellos match → 2-Way → database exchange → Full → LSAs in the database → shortest path computed → route installed

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
Protocol behaviour per standard; Cisco IOS / IOS XE command examples.
Applicability is projected only from persisted Topic profile and Command metadata.
At a glance

Operational reference

Fast context before you go deeper.

PlatformProtocol behaviour per standard; Cisco IOS / IOS XE command examples.
Scope / prerequisiteStart here when a neighbour does not come up, a route is missing or takes an unexpected path, or to read OSPF in a capt…
What next?1 suggested next step
Child topics (this level)23
Evidence0
On this pageJump to a specific section
Command lookup Jump straight to Cisco syntax
Drill down

Subtopics

Go one level deeper into this subject.

Subtopic OSPF Packet Types Reference

OSPF uses Hello, Database Description, Link-State Request, Link-State Update and Link-State Acknowledgment packets to form and synchronize adjacencies.

Subtopic OSPF Neighbor States Reference

OSPF neighbors progress through Down, Attempt, Init, 2-Way, ExStart, Exchange, Loading and Full as adjacency requirements are satisfied.

Subtopic OSPF LSA Types Reference

OSPF Link-State Advertisements describe topology and reachability information in the LSDB; LSA type determines origin, scope and meaning.

Subtopic OSPF Area Types Reference

OSPF area types control flooding boundaries and which external/inter-area information is represented inside an area.

Subtopic OSPF Cost & Path Selection Reference

OSPF chooses intra-area paths using accumulated interface cost; interface cost is explicit or derived from reference bandwidth and interface bandwidth.

Subtopic OSPF Network Types Deep Reference

OSPF network type controls neighbor discovery behavior, DR/BDR election expectations, timer defaults and how next-hop/adjoining behavior is modeled on an interface.

Subtopic OSPF DR / BDR Election Deep Reference

OSPF elects a Designated Router and Backup Designated Router on multiaccess segments to reduce adjacency and LSA exchange complexity.

Subtopic OSPF Timers & Authentication Deep Reference

OSPF Hellos and Dead timers gate neighbor liveness while authentication protects control-plane adjacency from unauthenticated peers.

Subtopic OSPF Summarization & Filtering Deep Reference

OSPF can summarize or filter routing information at specific topology boundaries; the mechanism depends on route/LSA type and ABR/ASBR role.

Subtopic OSPF Virtual Link Reference

An OSPF virtual link logically extends Area 0 connectivity through a transit area when a non-backbone area cannot attach directly to the backbone.

Subtopic OSPF DBD / ExStart / MTU Evidence Reference

OSPF ExStart and Exchange are database-synchronization phases where peers negotiate DBD master/slave behavior, sequence numbers and database-description exchange.

Subtopic OSPF External E1 vs E2 Reference

OSPF external routes can use Type 1 or Type 2 external metrics, which differ in how internal OSPF cost contributes to path comparison.

Subtopic OSPF NSSA Type-7 → Type-5 Translation Reference

NSSA allows external redistribution inside a not-so-stubby area by using Type-7 LSAs, which can be translated to Type-5 LSAs by an eligible ABR for the rest of the OSPF domain.

Subtopic OSPF External Forwarding Address Reference

The Forwarding Address in an OSPF external LSA can direct traffic toward a next hop other than the advertising ASBR itself.

Subtopic OSPF Router ID Selection & Duplicate RID Reference

OSPF Router ID is a 32-bit identifier used in neighbor identity, LSA origination and election tie-breaks; it is not required to be an address configured on a forwarding interface.

Subtopic OSPF Passive Interface & Default Origination Reference

Passive interfaces and default-information origination solve different OSPF boundaries: passive suppresses neighbor Hellos on an interface while still allowing the connected network to participate; default origination injects a default route according to configured conditions.

Subtopic OSPF LSA Header Field Reference

OSPF LSA Header Field Reference maps the common 20-byte OSPFv2 LSA header as the identity, version, lifetime and integrity boundary shared by every OSPFv2 LSA before its type-specific body is interpreted from a decoded control-plane object to the next protocol and forwarding boundary.

Subtopic OSPF DBD Field & Sequence Reference

OSPF DBD Field & Sequence Reference maps OSPF Database Description packet fields during ExStart and Exchange, especially Interface MTU, Options, I/M/MS flags, DD sequence numbers and the summarized LSA headers used for LSDB synchronization from decoded packet fields to the next protocol-state boundary.

Subtopic OSPF Router & Network LSA Field Reference

OSPF Router & Network LSA Field Reference maps the Type-1 and Type-2 LSA bodies that construct the intra-area SPF graph from router links, metrics, transit-network pseudonodes and attached-router membership from a decoded control-plane object to the next protocol and forwarding boundary.

Subtopic OSPF Summary / External / NSSA LSA Field Reference

OSPF Summary / External / NSSA LSA Field Reference maps the field semantics that separate inter-area summaries, ASBR reachability and external/NSSA routes, including metric type, Forwarding Address and route tag boundaries from a decoded control-plane object to the next protocol and forwarding boundary.

Subtopic OSPF Hello Field Reference

OSPF Hello Field Reference maps OSPFv2 Hello packet fields as the first packet-level proof for neighbor discovery, bidirectional recognition and DR/BDR context before database synchronization from decoded packet fields to the next protocol-state boundary.

Subtopic OSPF LSR / LSU / LSAck Field Reference

OSPF LSR / LSU / LSAck Field Reference maps OSPF Link State Request, Link State Update and Link State Acknowledgment fields as one correlated reliable-flooding transaction identified by LSA type, Link State ID and Advertising Router from decoded packet fields to the next protocol-state boundary.

Subtopic OSPF Options Bit Reference

OSPF Options Bit Reference maps OSPF Options as protocol capability and area-context signaling carried in Hellos, DBDs and LSA headers, with emphasis on comparing peer semantics instead of treating the octet as a generic health value from a decoded control-plane object to the next protocol and forwarding boundary.

Key points

Neighbours must agree on area, subnet, hello and dead timers, authentication, area type and MTU. Full is the normal final state — or 2-Way between two non-designated routers on a LAN. Stuck in ExStart or Exchange usually means MTU. Areas connect through area 0.

Key checks
  • show ip ospf neighbor — neighbours with state and role.
  • show ip ospf interface brief — OSPF interfaces with area, cost and state.
  • show ip ospf interface <interface> — timers, network type, authentication.
  • show ip ospf database — the LSAs by type and area.
  • show ip route ospf — the routes OSPF installed.
  • show ip protocols — router ID, networks and redistribution.
ReferenceWhat it is1 section · depth on demand

What this group covers

OSPF packet types and neighbour states, LSA types and fields, area types, cost, DR/BDR election, timers and authentication, summarisation, virtual links, E1/E2, NSSA translation and router ID selection. Go to *OSPF Neighbor States* for adjacency problems and the LSA references for database questions.

ReferenceImportant terms & boundaries2 sections · depth on demand

Where to look

QuestionReference
Why is the neighbour stuck in EXSTART?*OSPF DBD / ExStart / MTU Evidence Reference*
Which neighbour state means what?*OSPF Neighbor States Reference*
What does this LSA type carry?*OSPF LSA Types Reference*
Why was this path chosen?*OSPF Cost & Path Selection Reference*
Why is there no DR?*OSPF DR / BDR Election Deep Reference*
E1 or E2?*OSPF External E1 vs E2 Reference*
Duplicate router ID?*OSPF Router ID Selection & Duplicate RID Reference*

OSPF is the most widely used interior routing protocol in enterprise networks. Routers form neighbour relationships, exchange a complete map of the topology within each area, and calculate the shortest paths themselves. Most OSPF problems are neighbours that never form or stall, and their state tells you which setting to check.

OSPF quick reference:

show ip ospf neighbor
show ip ospf interface brief
show ip ospf database
show ip route ospf

Neighbour states should reach FULL (or 2-WAY between DROTHERs). Stuck in EXSTART/EXCHANGE = MTU mismatch; no neighbour at all = area, subnet, hello/dead timers, authentication or passive interface mismatch.

In depth

OSPF is the most widely used link-state interior routing protocol. Routers form adjacencies, share link-state information so each has a map of its area, and calculate shortest paths with SPF. Areas around a backbone (area 0) keep large networks scalable.

TopicKey idea
Neighbors/adjacencyHellos with matching parameters, then database sync
DR/BDRReduce adjacencies on multiaccess links
LSAs and LSDBShared topology database
CostBandwidth-based metric
AreasContain topology detail, summarise at ABRs

Most OSPF problems are neighbor problems (mismatched parameters or MTU) or design problems (areas, summarisation, filtering).

Confirmation

Confirm action

Continue?