Read an Excerpt
1. Routing PrinciplesThis chapter covers the principles of routing. Classful and classless routing are reviewed, as are the differences between distance vector and link-state routing protocol behavior. Convergence issues surrounding the most commonly used interior routing protocols for the Internet Protocol (IP) are also presented.
After reading this chapter, you will be able to list the key information routers need to route data, describe classful and classless routing protocols, compare distance vector and linkstate protocol operation, and describe the use of the fields in a routing table. Finally, given a preconfigured network, you should be able to discover the topology, analyze the routing table, and test connectivity using accepted troubleshooting techniques.
Routing FundamentalsThis section reviews routing in general, the requirements for routing, and how routing decisions are made, including the use of administrative distance and metrics.
Routing is a relay process in which items are forwarded from one location to another. In computer networks, user-generated traffic-such as electronic mail or graphic and text documents-is forwarded from a logical source to a logical destination. Each device in the network has a logical address so that it can be reached individually; in some cases, devices can also be reached as part of a larger group of devices.
For a muter to act as an effective relay device, it must have knowledge of the logical topology of the network and be capable of communicating with its neighboring devices. A router can be configured to recognize several different logical addressing schemes and to regularly exchange topology information with other devices in the network.
The mechanism of learning and maintaining awareness of the network topology is considered to be the routing function. The actual movement of transient traffic through the muter, from an inbound interface to an outbound interface, is a separate function and is considered to be the switching function. A routing device must perform both the routing and the switching functions to be an effective relay device.
NOTE: Appendix E, "Open System Interconnection (OSI) Reference Model," contains a review of the Open System Interconnection (OSI) reference model. Under this reference model, a router is an OSI Layer 3 device that has an understanding of the logical topology of the network. The routing and switching functions described here refer to the forwarding of a Layer 3 protocol data unit (PDU), also referred to as a packet (or datagram). A packet contains a logical source and a logical destination address that the routing device interprets during the packet forwarding process.
A router must know three items in order to route:
For a routing device to make a routing decision, it must first understand the logical destination address. For this to happen, the protocol suite that uses that logical addressing scheme must be enabled and currently active on the router. Some examples of common protocol suites are Transmission Control Protocol/Internet Protocol (TCP/IP), Internetwork Packet Exchange (IPX), and Digital Equipment Corporation's DECnet.
After the router can understand the addressing scheme, the second decision is to determine whether the destination logical network is a valid destination within the current routing table. If the destination logical network does not exist in the routing table, routing devices might be programmed to discard the packet and to generate an error message (for example, an IP Internet Control Message Protocol [ICMP] message) to notify the sender of the event. Some network managers have successfully reduced the size of their network's routing tables by including only a few destination networks and then specifying a default route entry. If specified, a default route will be followed if the destination logical network is not included as part of the device's routing table.
The final decision that the routing device must make if the destination network is in the routing table is to determine through which outbound interface the packet will be forwarded. The routing table will contain only the best path (or paths) to any given destination logical network. The best path to a destination network will be associated with a particular outbound interface by the routing protocol process. Routing protocols use a metric to determine the best path to a destination. A smaller metric indicates a preferred path; if two or more paths have an equal lowest metric, then all those paths will be equally shared. Sharing packet traffic across multiple paths is referred to as load balancing to the destination. When the outbound interface is known, the router must also have an encapsulation method (in other words, a Layer 2 frame type) to use when forwarding the packet to the next-hop logical device in the relay path.
The information required to perform the routing operation is included in the router's routing table and is generated by one or more routing protocol processes. The routing table is composed of multiple entries, each of which indicates the following:
The routing process is responsible for selecting the best path to any destination network. Because more than one learning mechanism can exist on a router at any given time, a method to choose between routes is needed when the same route is learned from multiple sources. For IP within a Cisco router, the concept of an administrative distance is used as a selection method for IP routing protocols.
Administrative distance is used as a measure of the trustworthiness of the source of the IP routing information. It is important only when a router learns about a destination route from more than one source.
Lower values of administrative distance are preferred over higher values. In general, default administrative distances have been assigned with a preference for manual entries over dynamically learned entries, and routing protocols with more sophisticated metrics over routing protocols with simple metrics. A comparison chart of the default administrative distances is presented in Table 1-2...