---
title: "Distance vector vs link state routing"
subject: "Computer Networks and Security"
chapter: 4
key: "semester_7/computer_networks_and_security:dv-vs-link-state"
source: https://www.bctengineer.com/q/semester_7/computer_networks_and_security/dv-vs-link-state
site: BCT Engineering
---

# Distance vector vs link state routing

Computer Networks and Security · Chapter 4: Network Layer

- Asked in: 2074 Asoj; 2073 Shrawan, 4 marks; 2072 Kartik, 6 marks; 2071 Shrawan, 6 marks; 2070 Asar, 4 marks; year not given (asked 5 times)
- Video: [CN 20 : Distance Vector VS Link State Routing | Examples](https://www.youtube.com/watch?v=0Q3SEa9qyAI) — CS & IT Tutorials by Vrushali 👩‍🎓
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_7/computer_networks_and_security/dv-vs-link-state
- Whole chapter: https://www.bctengineer.com/md/semester_7/computer_networks_and_security/chapter-4

## Question

Differentiate between link state and distance vector routing (compare the operation of link state routing with distance vector routing).

## Short answer

Distance vector protocols share whole routing tables with neighbours, use Bellman-Ford, and converge slowly. Link state protocols flood link states to all routers, build a complete topology map, use Dijkstra, and converge fast. RIP is DV; OSPF is LS.

## Answer

**Distance vector (DV)** routing: each router tells its **neighbours** its whole routing table (distances to all destinations) periodically, and learns routes by the Bellman-Ford algorithm. **Link state (LS)** routing: each router floods information about the state of its **own links** to **all routers**; each router then builds the full network map and computes shortest paths using Dijkstra's algorithm.

| Point | Distance vector | Link state |
|---|---|---|
| Information shared | Whole routing table | Only the state/cost of its own links |
| Shared with | Directly connected neighbours only | All routers in the area (flooding) |
| When | Periodic (e.g. every 30 s in RIP) | When a change occurs (plus a refresh) |
| Algorithm | Bellman-Ford | Dijkstra |
| Knowledge of topology | Only distance and next hop ("routing by rumour") | Complete topology map |
| Convergence | Slow; count-to-infinity problem | Fast; loop-free |
| Bandwidth use | High (periodic tables) | Low in steady state, high at startup |
| CPU / memory | Low | High |
| Metric | Hop count (RIP) | Cost based on bandwidth, delay (OSPF) |
| Scalability | Small networks (RIP max 15 hops) | Large networks, hierarchical areas |
| Examples | RIP, IGRP | OSPF, IS-IS |

DV is easier to configure but converges slower; LS is more complex and resource-hungry but more reliable for large networks.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. In distance vector routing, what is shared and with whom?
   A. Own link states with all routers
   B. Whole routing table with directly connected neighbours
   C. Topology map with neighbours
   D. Only changes with all routers
   Answer: B. DV sends the whole table periodically to neighbours. (Key point: DV sharing)

2. Which pairing is correct?
   A. DV: Dijkstra, LS: Bellman-Ford
   B. DV: Bellman-Ford, LS: Dijkstra
   C. Both Dijkstra
   D. Both Bellman-Ford
   Answer: B. DV uses Bellman-Ford; LS runs Dijkstra on the full map. (Key point: Algorithms)

3. Which has count-to-infinity problem?
   A. Link state
   B. Distance vector
   C. Both
   D. Neither
   Answer: B. DV converges slowly and suffers count-to-infinity. (Key point: Convergence)

4. What does a link state router know?
   A. Only distance and next hop
   B. The complete topology map
   C. Only neighbours
   D. Nothing
   Answer: B. Flooded link-state info lets each router build the full map. (Key point: LS knowledge)

## Related in Computer Networks and Security

- [Routed vs routing protocol](https://www.bctengineer.com/question.md?key=semester_7%2Fcomputer_networks_and_security%3Arouted-vs-routing-protocol) — Computer Networks and Security, chapter 4
- [Compare OSI and TCP/IP models](https://www.bctengineer.com/question.md?key=semester_7%2Fcomputer_networks_and_security%3Aosi-vs-tcpip) — Computer Networks and Security, chapter 1, asked 4×
- [Error correction vs detection, bit stuffing](https://www.bctengineer.com/question.md?key=semester_7%2Fcomputer_networks_and_security%3Aerror-correct-detect-bitstuff) — Computer Networks and Security, chapter 3
- [Symmetric vs asymmetric key encryption](https://www.bctengineer.com/question.md?key=semester_7%2Fcomputer_networks_and_security%3Asymmetric-vs-asymmetric) — Computer Networks and Security, chapter 8, asked 3×

## Related in other subjects

- [Link-state and distance vector routing](https://www.bctengineer.com/question.md?key=semester_8%2Ftelecommunications%3Alink-state-distance-vector) — Telecommunications, chapter 8
- [Link-state routing as adaptive routing](https://www.bctengineer.com/question.md?key=semester_8%2Ftelecommunications%3Alink-state-adaptive-example) — Telecommunications, chapter 8
- [Numerical: reverse link distance by link budget](https://www.bctengineer.com/question.md?key=semester_7%2Fwireless_communication%3Alink-budget-reverse-link-distance) — Wireless Communication, chapter 3
- [Link analysis in web vs cloud](https://www.bctengineer.com/question.md?key=semester_8%2Finformation_system%3Alink-analysis-web-vs-cloud) — Information System, chapter 7
