Routing Sources
Objective:
- Describe basic routing concepts (including: packet forwarding, router lookup process)
Routers are methodical, tactless devices in that they do not necessarily care about the individual IP addresses that exist on a subnet. Their sole obsession is to maintain their routing logic
by keeping track of the networks that exist and which interfaces to use to send the traffic if an IP packet is destined for that network. By using routing devices to relay packets out of their interfaces to other forwarding devices or the destination network, the IP packet eventually reaches the destination.
At the heart of the routing logic for Layer 3 devices is the routing table. This table, located in volatile RAM, contains a mapping of all the best routes to networks that the router is aware of and the interfaces to exit to reach those networks. So how is the router aware of these networks? Generally, three routing sources can feed the routing table with this information:
- Connected interfaces: As soon as you assign an IP address to a working (up/line protocol up) interface, the router associates the entire subnet of the interface’s IP address in the routing table.
- Static routes: These are manual entries that an administrator enters into the configuration to specify the destination network and the next hop (router along the destination path).
- Routing protocols: Protocols exchanged between routing devices to dynamically advertise networks. Connected interfaces remain in the routing tables as long as the interface is active and has a valid IP address assigned to it. Static routes remain in the table as long as you do not remove the static route configuration and the next hop is valid (the interface to the next hop is up). Networks learned from dynamic routing protocols remain in the routing table as long as the next hop is valid and the routing devices do not stop hearing the network(s) being advertised from the neighbor routers.
Administrative Distance
Now that you are aware of the multiple sources of routing information, you must consider a feasible anomaly that could occur with your routing sources. Namely, if you have several
sources of information such as connected interfaces, static routes, and multiple routing protocols, which one are you to trust when more than one source advertises the same network? For example, if a router learns about the 192.168.1.0/24 network from a routing protocol and a static route, how does the router decide which entry to place into its routing table?
The answer lies within a program logic in the IOS called the administrative distance. The administrative distances are values between 1 and 255 that are assigned to routing information sources. These values represent a level of trustworthiness of the information source, in which lower administrative distances are preferred over higher ones.
NOTE
The administrative distance applies only when multiple sources are advertising exactly the same subnet.
Table 10.1 lists the Cisco IOS default administrative distances for some of the routing sources.
It should come as no shock that connected interfaces are the most trustworthy sources because they are connected directly to the local router. Static routes have a low administrative distance of 1 because the Cisco IOS assumes that you are competent administrators and any manual entry of a routable network is trusted over any dynamic routing protocols such as EIGRP, OSPF, and RIP.
EXAM ALERT
Memorizing the default administrative distances serves as a resourceful tool in answering questions on the CCENT and CCNA exams.