Routers use the routing table to make forwarding decisions. In the routing table, they keep only the best path if multiple paths to the destination network exist.
Different routing protocols use different approaches to select the best path. For example, distance vector routing protocols use the number of routers to calculate and select the best and shortest path from all available paths between the source and destination.
The number of routers reflects the term Distance. The term Vector indicates the direction to the remote network. On a path, each router is a hop. For example, if a path has five routers, you can say it has five hops.
Distance vector routing selects the path having the least number of routers. For example, if a router has three paths having 2, 3, and 4 hops ( routers) to a destination network, it will select the path that has two hops (routers).
RIP, RIPv2, IGRP, and EIGRP are distance-vector routing protocols. Distance-vector routing protocols explore all network paths, select the path having the least number of hops for each destination, and add it to the routing table.
In distance-vector routing, a router periodically advertises its distance value to other routers and receives similar advertisements from other routers. It uses the received advertisements to populate its routing table. In the next advertisement cycle, it advertises updated information from its routing table. This process continues until the routing tables of all routers have information about all available subnets in the network.
Distance vector routing is simple and straightforward. You can easily configure it on any router. Since it uses a simple hop-based algorithm, managing and troubleshooting it is also easier.
It uses a hop-based algorithm. A hop-based algorithm always selects the shortest path. In many circumstances, the shortest path could be slower than the longest path.
Let us take an example. In the following network, router A has two paths to reach the destination. Path A has only one hop. Path B has two hops.
Although path A has less hop than path B, it is not faster than path B.
Path B is faster than path A. But if we run distance vector routing on this network, router A will always take path A to reach the destination.
A traditional distance vector routing protocol can not measure the bandwidth the path has. To overcome this issue, advanced distance vector routing protocols known as hybrid routing protocols were created.
Distance vector routing creates more traffic than other routing methods. It broadcasts routing updates at a fixed interval, even if there are no changes in the network topology. It wastes a lot of network bandwidth and creates congestion in the network.