Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

A link-state routing protocol lets routers build a shared picture of network topology and calculate routes from it. Each router advertises information about its local links; routers distribute those advertisements, assemble a topology database, and independently calculate paths. OSPF Version 2 (OSPFv2) is a standards-defined example.

What does “link-state” mean?

“Link state” refers to information about a router’s local connections: which links or interfaces are usable and which neighboring routers can be reached through them. In a link-state routing protocol, routers share this information so they can work from a description of the network’s topology.

As RFC 2328 puts it, “In a link-state routing protocol, each router maintains a database describing the Autonomous System’s topology.” That database is called the link-state database.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

How does link-state routing work?

  1. Routers describe local links. Each router originates information about its own part of the network.
  2. They distribute that information. In OSPFv2, routers flood Link State Advertisements (LSAs) so the information can reach other routers in the relevant area.
  3. Routers build a topology database. The collected LSAs form the link-state database. In OSPFv2, routers in the same area maintain a common database for that area.
  4. Each router calculates paths. Using the database, a router constructs a shortest-path tree rooted at itself, then derives routes from that tree.

RFC 2328 specifies Dijkstra’s algorithm for OSPFv2’s shortest-path calculation. The calculation is performed by each router using its own position as the tree’s root; routers do not simply receive one centrally computed set of paths.

How OSPFv2 illustrates the idea

OSPFv2 is a concrete example, not a synonym for every link-state protocol. Its LSAs describe parts of the routing domain, and the collection of those advertisements forms the link-state database. Routers synchronize databases with adjacent routers, then calculate paths through the topology represented for their area.

RFC 2328, the OSPF Version 2 specification, was published in April 1998. Its description is useful for understanding the core link-state model, but OSPFv2’s specific advertisements, packet formats, and operating details should not be assumed to apply identically to every protocol in the family.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

In brief: the defining difference

A link-state protocol has routers distribute descriptions of their local links, assemble a topology database, and calculate routes from that database. In OSPFv2, the advertisements are LSAs and the route calculation creates a shortest-path tree for each router.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Source: RFC 2328: OSPF Version 2, RFC Editor / IETF.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.