What is Link-State Routing?
Link-State Routing is a dynamic routing algorithm where each router builds a complete map of the network and uses Dijkstra’s Shortest Path Algorithm to determine the best path to a destination. Unlike Distance Vector Routing, which relies only on neighbor information, Link-State Routing provides a global view of the network.
- Uses Link-State Advertisements (LSAs) to share information about network topology.
- Each router maintains a Link-State Database (LSDB) to store network topology.
- Faster convergence and loop-free by design.
How Link-State Routing Works
1. Discovering Neighbors (Hello Protocol)
- Each router sends a Hello packet to discover directly connected neighbors.
- Routers form adjacencies with their neighbors.
2. Exchanging Link-State Advertisements (LSAs)
- Each router floods LSAs to all routers in the network.
- LSAs contain information about:
- Directly connected networks.
- Neighboring routers.
- Link costs (bandwidth, delay, reliability).
3. Building the Link-State Database (LSDB)
- Routers store received LSAs in a Link-State Database (LSDB).
- Each router has an identical LSDB for accurate decision-making.
4. Computing the Best Path (Dijkstra’s Algorithm)
- Each router runs Dijkstra’s Shortest Path First (SPF) Algorithm on the LSDB.
- Calculates the shortest path to every network.
- Updates the routing table accordingly.
5. Maintaining Routing Information
- If a network change occurs, routers flood updated LSAs.
- Incremental updates minimize network traffic.
Example of Link-State Routing Process
Step 1: Initial Network Setup
Consider a network with four routers:

- Each router knows its directly connected links.
Step 2: LSAs Flooding
- Router A sends LSAs:
- “I am connected to B and C, link cost = 10, 5.”
- Router B sends LSAs:
- “I am connected to A, C, and D, link cost = 10, 3, 2.”
- All routers receive and store these LSAs in their LSDB.
Step 3: Shortest Path Calculation (Dijkstra’s Algorithm)
Each router runs Dijkstra’s Algorithm to calculate the best route:
Router | Destination | Next Hop | Cost |
---|---|---|---|
A | D | B → D | 12 |
B | C | B → C | 3 |
C | A | C → A | 5 |
D | A | D → B → A | 12 |
- If a link fails, routers flood new LSAs, and all routers recalculate paths dynamically.
Routing Protocols Using Link-State Routing
Protocol | Type | Metric | Best For |
---|---|---|---|
OSPF (Open Shortest Path First) | Link-State | Cost (Bandwidth) | Enterprise Networks |
IS-IS (Intermediate System to Intermediate System) | Link-State | Cost (Default = 10) | Large ISPs |
BGP (Border Gateway Protocol) | Path-Vector | AS Path | Internet Routing |
Key Features of Link-State Routing
- Loop-Free by Design
- Each router has a full network map, preventing loops.
- Faster Convergence
- Updates are triggered (event-driven), unlike Distance Vector’s periodic updates.
- Scalability
- Works well in large networks with thousands of routers.
- Efficient Bandwidth Usage
- LSAs are sent only when topology changes, reducing network overhead.
- Supports Hierarchical Routing (OSPF Areas)
- Divides large networks into smaller areas for efficiency.
OSPF (Open Shortest Path First) – Link-State Protocol Example
1. OSPF Areas
- Area 0 (Backbone Area): Core of the OSPF network.
- Other Areas: Connect to Area 0 for better scalability.
2. OSPF Packet Types
Packet Type | Description |
---|---|
Hello | Discovers neighbors. |
LSR (Link-State Request) | Requests missing LSAs. |
LSU (Link-State Update) | Sends LSAs to neighbors. |
LSAck (Link-State Acknowledgment) | Confirms LSA receipt. |
Comparison: Link-State vs Distance Vector Routing
Feature | Link-State Routing | Distance Vector Routing |
---|---|---|
Algorithm | Dijkstra’s SPF | Bellman-Ford |
Network View | Full network topology | Only neighbors’ info |
Convergence Speed | Fast | Slow |
Loop Prevention | Built-in | Uses techniques (split horizon, poison reverse) |
Update Method | Event-driven (efficient) | Periodic (bandwidth-consuming) |
Scalability | High (OSPF, IS-IS) | Low (RIP max 15 hops) |
Advantages of Link-State Routing
✔ Faster convergence – Responds quickly to topology changes.
✔ More efficient – Sends updates only when needed.
✔ Scalable – Works well for large networks (OSPF, IS-IS).
✔ Loop-free – Each router has complete network topology.
Disadvantages of Link-State Routing
❌ Higher memory and CPU usage – Stores full topology.
❌ More complex configuration – Requires skilled network engineers.
❌ Increased initial traffic – LSAs flooding can be bandwidth-intensive.
Real-World Application of Link-State Routing
1. Large Enterprises & Data Centers (OSPF)
- Google, Amazon, and Microsoft use OSPF in their internal networks.
2. Internet Service Providers (ISPs – IS-IS)
- ISPs use IS-IS to manage high-speed, large-scale networks.
3. Global Internet Routing (BGP)
- BGP, a modified link-state protocol, powers internet backbone routing.
Conclusion
Link-State Routing is an efficient, scalable, and loop-free routing approach used in large networks. It provides fast convergence, detailed topology knowledge, and reliable data transmission. OSPF and IS-IS are the most widely used Link-State Protocols.