Table of Contents
Only the best route to the destination network is registered in the routing table.
The route of a certain network can be configured as a static route, but can also be learned by a routing protocol. We can also run multiple routing protocols instead of just one, and learn the route information of a certain network from multiple routing protocols. In other words, the route information of a network may be learned from multiple sources. Even if multiple route information is learned, in principle, only the best route is registered in the routing table.
When route information for a given network is learned from multiple sources
As shown in the following figure, consider the case where the route information for 192.168.10.0/24 on R1 is not only configured as a static route, but is also learned through RIP and OSPF. The R1 has to decide which one is the best route.
Metrics are the criteria for determining the best route to a given network. Metric indicates the distance to the destination network. However, metric has no meaning in route information configured for static routes; on Cisco routers, the metric for static routes is “0”. Also, we cannot simply compare metric values because different routing protocols have completely different ideas of metric and the range of possible values. Simply comparing metric values is like trying to simply compare one “meter” to one “foot” in terms of real-world distances. The metric for each routing protocol is shown in the table below.
Routing Protocol | Metrics |
RIP | Hop count |
OSPF | Path cost |
EIGRP | Composite Metrics(BW , Delay , Load , Reliability , MTU) |
In the figure, priority is given to clarity, and there are some differences from the actual behavior. The OSPF route information will not necessarily be the network address/subnet mask + metric as shown in the figure. Also, the metric of the OSPF route on R1 will be increased from the metric of the received route information.
Distance to destination network = Administrative distance/metric
When comparing distances with different units, such as 1 “meter” and 1 “foot” in the real world, the units must be aligned. The parameter used to adjust the units when comparing metrics is the Administrative Distance. Combining the administrative distance and the metric as the distance to the destination network allows us to compare the distances of routes with different sources of information, such as static routes, RIP routes, and OSPF routes.
Distance to destination network = Administrative distance/metric
Shorter distances are better, so smaller values are preferred for both the administrative distance and the metric. The smaller the value of the administrative distance, the shorter the distance is considered to be, since it is preceded by the administrative distance. The default value of the administrative distance is as shown in the following table.
Route Source | Administrative Distance value |
Connected | 0 |
Static route | 1 |
BGP | 20 |
EIGRP | 90 |
OSPF | 110 |
RIP | 120 |
External EIGRP | 170 |
IBGP | 200 |
Considering the distance of the route information for 192.168.10.0/24 in the previous configuration example, we have the following
Distance to 192.168.10.0/24
Static route:[1/0]
RIP route:[120/3]
OSPF route:[110/10]
Since the static route has the shortest distance, the route information of the static route will be registered in the routing table as the best route for 192.168.10.0/24.
The value of the administrative distance can also be changed from the default. If you change the administrative distance, you can choose which information source to register as the route information in the routing table when the route information of a certain network is learned from multiple sources.
Also, Administrative Distance is a parameter that is used locally on the router. It is not included in the route information advertised by the routing protocol.
summary
Summary
- Only the best route to the destination network is registered in the routing table. To determine the best route, the distance to the destination network is measured.
- In the route information sent by each routing protocol, there is a metric value that measures the distance to the destination network. However, since each routing protocol has a different concept of metric, it is not possible to simply compare metric values for different routing protocols.
- The administrative distance makes it possible to compare the values of different metrics for different routing protocols.
- Distance to destination network = Administrative distance/metric
IP Routing Basic
- Router – The central device that performs routing
- Dividing Network with router
- Layer3 Switch Overview
- Measuring the distance to the destination network -Administrative Distance and Metric
- Equal Cost Multi Path Load Balancing
- Cisco Static Route Configuration
- Example of Cisco Static Route Configuration Step by Step
- RIP Split horizon
- RIP Timers
- RIP Route Poisoning – Quickly remove unnecessary route information
- Cisco RIP Basic Configuration and Verification Commands
- Cisco RIP Configuration Example
- Generating a default route in RIP – Redistribution of static route
- Passive-Interface ~Stops Routing Protocols from Sending Packets
- Default Gateway Redundancy Overview
- How the Cisco HSRP works
- Configuring and Verifying Cisco HSRP
- How VRRP works
- Configuring and Verifying commands for VRRP [Cisco]