Packets originating from a nonrouting device destined for another network are sent to their default gateway (Layer 3 device on segment). The router consults its routing table to deter-mine if the destination network can be reached. If not, the ICMP Destination Unreachable message is sent to the source. If so, packet is forwarded out interface associated with the destination network in routing table.
Default Administrative Distances
Maximum Hop Counts
|RIPv1 and v2|
Static and Default Routes
Static routes are useful in stub networks in which we want to control the routing behavior by manually configuring destination networks into the routing table:
Router(config)#ip route 10.0.0.0 255.0.0.0 192.168.2.5
A floating static route can be configured when redundant connections exist and you want to use the redundant link if the primary fails. This is configured by adding a higher administrative distance at the end of a static route:
Router(config)#ip route 10.0.0.0 255.0.0.0 192.168.2.9 2
A default route is a gateway of last resort for a router when there isn’t a specific match for an IP destination network in the routing table (such as packets destined for the Internet):
Router(config)#ip route 0.0.0.00.0.0.0serial 0/0
With routing protocols, you can specify a default network, which is a network in the routingtable that routing devices consider to be the gateway of last resort. Using their routing protocols, they determine the best path to the default network:
Router(config)#ip default-network 192.168.1.0
Dynamic Routing Protocols
In complex networks with multiple pathways to destinations, dynamic routing protocols enable routers to advertise their networks to each other and dynamically react to topology changes.
Routing protocols determine the best path based on the lowest metric.
Because one of the core responsibilities of routing protocols is to build routing tables to determineoptimal routing paths, we need to have some means of measuring which routes are preferred whenthere are multiple pathways to a destination. Routing protocols use some measure of metrics toidentify which routes are optimal to reach a destination network. The lowest cumulative metric toa destination is the preferred path and the one that ultimately enters the routing table. Different routing protocols use one or several of the following metrics to calculate the best path.
The number of routing devices that the packet must travel to reach a destination network
The cumulative bandwidth of the links to the destination in kilobits per second
The length of time (measured in microseconds) a packet takes from source to destination
The consistency of the links and paths toward the destination based on error rates of the interfaces
The cumulative amount of congestion or saturation of the links toward the destination
The maximum frame size that is allowed to traverse the links to the destination
|Cost||An arbitrary number typically based on the link’s bandwidth|
Interior and Exterior Gateway Routing Protocols
- Interior gateway routing protocols: IG routing protocols advertise networks and metrics within an autonomous system.
- Exterior gateway routing protocols: EG routing protocols advertise networks in between autonomous systems.
Classful and Classless Routing Updates
- Classful routing: The routing updates only contain the classful networks without any subnet mask. Summarization is automatically done when a router advertises a network out an interface that is not within the same major subnet. Classful routing protocols must have a FLSM design and do not operate correctly with discontiguous networks.
- Classless routing: The routing updates can contain subnetted networks because the subnet mask is advertised in the updates. Route summarization can be manually configured at any bit boundary. Classless routing protocols support VLSM designs and discontiguous networks.
Routing Protocol Classes
- Distance vector: The entire routing table is periodically sent to directly connected neighbors regardless of a topology change. These routing protocols manipulate the routing table updates before sending that information to their neighbors and are slow to converge when a topology change occurs.
- Link state: All possible link states are stored in an independent topology table in which the best routes are calculated and put into the routing table. The topology table is initially synchronized with discovered neighbors followed by frequent hello messages. These routing protocols are faster to converge than distance vector routing protocols.
- Hybrid: By using the best characteristics from link-state and routing protocols, these advanced routing protocols efficiently and quickly build their routing information and converge when topology changes occur.
Redistribution is the method of configuring routing protocols to advertise networks from other routing protocols:
- One-way redistribution: Networks from an edge protocol are injected into a more robust core routing protocol, but not the other way around. This method is the safest way to perform redistribution.
- Two-way redistribution: Networks from each routing protocol are injected into the other. This is the least preferred method because it is possible that suboptimal routing or routing loops might occur because of the network design or the difference in convergence times when a topology change occurs.
Distance Vector Routing Loop Mitigation
Distance vector routing protocols contain several measures to prevent routing loops:
Maximum hop counts: To ensure that routing metrics do not increment until infinity in a routing loop, distance vector routing protocols have a maximum hop count.
Distance Vector/Link State/Hybrid
Maximum Hop Count
Subnets learned from neighbor routers should not be sent back out the same interface from which the original update came.
Route poisoning with poison reverse:
When a route to a subnet fails, the subnet is advertised with an infinite metric. Routers receiving the poisoned route override the split horizon rule and send a poison reverse back to the source.
The amount of time a router ignores any information about an alternative route with a higher metric to a poisoned subnet.
Flash updates/triggered updates:
When a route fails, the router immediately shoots out an update as opposed to waiting for a normal update interval.