They do not know how many other routers are in the path toward any of those networks.
For this reason, distance vector protocols do not have a complete map of the whole network instead, their database reflects that a neighbor router knows how to reach the destination network and how far the neighbor router is from the destination network. Routers running distance vector protocols advertise the routing information to their neighbors from their own perspective, modified from the original route that it received. Once the best paths are determined, they are installed into the routing table and are advertised to each neighbor router. When a router receives routing information from a neighbor, it stores it in a local routing database as it is received and the distance vector algorithm (also known as Bellman-Ford and Ford-Fulkerson algorithms) is used to determine which paths are the best loop-free paths to each reachable destination.
Distance Vector Algorithmsĭistance vector routing protocols, such as RIP, advertise routes as vectors (distance, vector), where distance is a metric (or cost) such as hop count and vector is the next-hop router’s IP used to reach the destination: If it exchanges routes between different autonomous systems, it is known as an external BGP (eBGP) session.įigure 3-1 shows an illustration of how one or many IGPs as well as iBGP can be running within an autonomous system and how eBGP sessions interconnect the various autonomous systems together.įigure 3-1 Autonomous Systems and How They InterconnectĮGPs and IGPs use different algorithms for path selection and are discussed in the following sections. If BGP exchanges routes within an autonomous system, it is known as an internal BGP (iBGP) session. BGP is an EGP protocol but can also be used within an autonomous system. External gateway protocols (EGPs) route between autonomous systems. With the exception of BGP, the protocols in the preceding list are designed and optimized for routing within an autonomous system and are known as internal gateway protocols (IGPs).