Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
What is Distance Vector Routing Algorithm?
The Distance-Vector routing algorithm is a network routing protocol where each router shares its routing table with neighboring routers. It is also known as the Bellman-Ford routing algorithm, named after the researchers who developed it (Bellman 1957, and Ford and Fulkerson, 1962).
In this algorithm, each router calculates the shortest distance to every destination network by combining information from its neighbors. The algorithm operates on the principle that each router gradually builds complete network knowledge through iterative information sharing.
Key Features
-
Complete network knowledge − Each router maintains and shares information about the entire network topology.
-
Neighbor-only sharing − Routers exchange routing information only with directly connected neighbors.
-
Periodic updates − Routing tables are shared at regular intervals, typically every 30 seconds.
How Distance Vector Routing Works
Knowledge about the Entire Network
Each router maintains a routing table containing information about all networks in the autonomous system. When sharing updates, a router sends its complete routing table to all neighboring routers.
Routing Only to Neighbors
Information exchange occurs only between directly connected routers. Each router receives routing tables from its neighbors, processes the information, and updates its own table accordingly.
Information Sharing at Regular Intervals
Routers periodically broadcast their routing tables to neighbors, typically every 30 seconds. This ensures that network changes are propagated throughout the system and routing tables remain current.
Routing Table Structure and Updates
Each routing table contains three essential columns: Network ID, Cost (hop count), and Next Hop (neighboring router to reach destination).
Sample Initial Routing Tables
Router A Initial Table:
| Network ID | Cost | Next Hop |
|---|---|---|
| 24 | 1 | B |
| 23 | 1 | E |
| 18 | 2 | E |
Table Update Rules
When a router receives routing advertisements from neighbors, it applies these rules:
-
New destination − If the advertised destination is not in the routing table, add the new entry.
-
Same next-hop − If the destination exists and the next-hop is the same, replace the existing entry with the advertised one.
-
Different next-hop − If the advertised hop count is lower than the current entry, replace it. Otherwise, keep the existing entry.
Advantages and Disadvantages
| Advantages | Disadvantages |
|---|---|
| Simple to implement and understand | Slow convergence in large networks |
| Automatic route discovery | Count-to-infinity problem |
| Works well in small networks | High bandwidth consumption for updates |
Conclusion
Distance Vector routing is a fundamental routing protocol that enables routers to discover and maintain network paths through periodic information sharing with neighbors. While effective for smaller networks, it faces scalability challenges in larger topologies due to slow convergence and the count-to-infinity problem.
