Routing Technologies and Bandwidth Management
Date: Oct 28, 2021
In this sample chapter from CompTIA Network+ N10-008 Cert Guide, you will explore a variety of approaches for performing routing, including dynamic routing, static routing, and default routing. The chapter also breaks down the various categories of routing protocols and provides specific examples of each.
This chapter covers the following topics related to Objective 2.2 (Compare and contrast routing technologies and bandwidth management concepts) of the CompTIA Network+ N10-008 certification exam:
Routing
Dynamic routing
Protocols
Routing Information Protocol (RIP)
Open Shortest Path First (OSPF)
Enhanced Interior Gateway Routing Protocol (EIGRP)
Border Gateway Protocol (BGP)
Link state vs. distance vector vs. hybrid
Static routing
Default route
Administrative distance
Exterior vs. interior
Time to live
Bandwidth management
Traffic shaping
Quality of service (QoS)
In Chapter 4, “IP Addressing,” you learned how Internet Protocol (IP) networks can be divided into subnets. Each subnet is its own broadcast domain, and the device that separates broadcast domains is a router (which this text considers synonymous with a multilayer switch). A multilayer switch is a network device that can perform the Layer 2 switching of frames as well as the Layer 3 routing of IP packets. Multilayer switches generally use dedicated chips to perform these functions and, as a result, may be faster than traditional routers in forwarding packets.
For traffic to flow between subnets, the traffic has to be routed; this routing is a router’s primary job. This chapter discusses how routing occurs and introduces a variety of approaches for performing routing, including dynamic routing, static routing, and default routing. The chapter also breaks down the various categories of routing protocols and provides specific examples of each.
The chapter concludes with a discussion of various bandwidth management topics, including a discussion of QoS concepts, such as traffic shaping.
Foundation Topics
Routing
To understand basic routing processes, consider Figure 10-1. In this topology, PC1 needs to send traffic to Server1. Notice that these devices are on different networks. In this topology, how does a packet from the source IP address 192.168.1.2 get routed to the destination IP address 192.168.3.2?
FIGURE 10-1 Basic Routing Topology
It might help to walk through this process systematically:
Step 1. PC1 compares its IP address and subnet mask 192.168.1.2/24 with the destination IP address and subnet mask 192.168.3.2/24. PC1 concludes that the destination IP address resides on a remote subnet. Therefore, PC1 needs to send the packet to its default gateway, which could have been manually configured on PC1 or dynamically learned via Dynamic Host Configuration Protocol (DHCP). In this example, PC1 has the default gateway 192.168.1.1 (router R1). However, to construct a Layer 2 frame, PC1 also needs the MAC address of its default gateway. PC1 sends an Address Resolution Protocol (ARP) request for router R1’s MAC address. After PC1 receives an ARP reply from router R1, PC1 adds router R1’s MAC address to its ARP cache. PC1 now sends its data in a frame destined for Server1, as shown in Figure 10-2.
FIGURE 10-2 Basic Routing: Step 1
Step 2. Router R1 receives the frame sent from PC1 and interrogates the IP header. An IP header contains a Time-to-Live (TTL) field, which is decremented once for each router hop. Therefore, router R1 decrements the packet’s TTL field. If the value in the TTL field is reduced to 0, the router discards the frame and sends a “time exceeded” Internet Control Message Protocol (ICMP) message back to the source. As long as the TTL has not been decremented to 0, router R1 checks its routing table to determine the best path to reach network 192.168.3.0/24. In this example, router R1’s routing table has an entry stating that network 192.168.3.0/24 is accessible via interface Serial 1/1. Note that ARP is not required for serial interfaces because these interface types do not have MAC addresses. Router R1, therefore, forwards the frame out its Serial 1/1 interface, as shown in Figure 10-3.
FIGURE 10-3 Basic Routing: Step 2
Step 3. When router R2 receives the frame, it decrements the TTL in the IP header, just as router R1 did. Again, as long as the TTL has not been decremented to 0, router R2 interrogates the IP header to determine the destination network. In this case, the destination network 192.168.3.0/24 is directly attached to router R2’s Fast Ethernet 0/0 interface. Similar to the way PC1 sent out an ARP request to determine the MAC address of its default gateway, router R2 sends an ARP request to determine the MAC address of Server1. After an ARP reply is received from Server1, router R2 forwards the frame out its Fast Ethernet 0/0 interface to Server1, as illustrated in Figure 10-4.
FIGURE 10-4 Basic Routing: Step 3
The previous steps identified two router data structures:
IP routing table: When a router needed to route an IP packet, it consulted its IP routing table to find the best match. The best match is the route that has the longest prefix. Specifically, a route entry with the longest prefix is the most specific network. For example, imagine that a router has an entry for network 10.0.0.0/8 and for network 10.1.1.0/24. Also, imagine that the router is seeking the best match for destination address 10.1.1.1/24. The router would select the 10.1.1.0/24 route entry as the best entry because that route entry has the longest prefix (/24 is longer than /8, which is a more specific entry).
Layer 3 to Layer 2 mapping: In the previous example, router R2’s ARP cache contained Layer 3 to Layer 2 mapping information. Specifically, the ARP cache had a mapping that said MAC address 2222.2222.2222 corresponded to IP address 192.168.3.2.
As shown in the preceding example, routers rely on their internal routing table to make packet-forwarding decisions. So how does a router’s routing table become populated with entries? That is the focus of the next section.
Sources of Routing Information
A router’s routing table can be populated from various sources. As an administrator, you could statically configure a route entry. A route could be learned via a dynamic routing protocol (for example, OSPF or EIGRP), or a router could know how to get to a specific network because the router is physically attached to that network.
Directly Connected Routes
A router that has an interface directly participating in a network knows how to reach that specific destination network. For example, consider Figure 10-5.
In Figure 10-5, router R1’s routing table knows how to reach the 192.168.1.0/24 and 192.168.2.0/30 networks because router R1 has an interface physically attached to each network. Similarly, router R2 has interfaces participating in the 10.1.1.0/30 and 192.168.2.0/30 networks and therefore knows how to reach those networks. The entries currently shown to be in the routing tables of routers R1 and R2 are called directly connected routes.
FIGURE 10-5 Directly Connected Routes
Static Routes
It is also possible to statically configure routes in a router’s routing table. Continuing to expand on the previous example, consider router R1. As shown in Figure 10-6, router R1 does not need knowledge of each route on the Internet. Specifically, router R1 already knows how to reach devices on its locally attached networks. All router R1 really needs to know at this point is how to get out to the rest of the world. As you can see from Figure 10-6, any traffic destined for a nonlocal network (for example, any of the networks available on the public Internet) can simply be sent to router R2. Because R2 is the next router hop along the path to reach all those other networks, router R1 could be configured with a default static route, which says, “If traffic is destined for a network not currently in the routing table, send that traffic out interface Serial 1/1.”
Similarly, router R2 can reach the Internet by sending traffic out its Serial 1/0 interface. However, router R2 does need information about how to reach the 192.168.1.0/24 network available off router R1. To educate router R2 about how this network can be reached, a network administrator can add a static route pointing to 192.168.1.0/24 to router R2’s routing table.
FIGURE 10-6 Static Routes
Dynamic Routing Protocols
In complex networks, such as the topology shown in Figure 10-7, static routing does not scale well. Fortunately, a variety of dynamic routing protocols are available that allow a router’s routing table to be updated as network conditions change.
FIGURE 10-7 Dynamic Routes
In Figure 10-7, router R2 is advertising a default route to its neighbors (routers R1, R3, and R4). What happens if PC1 wants to send traffic to the Internet? PC1’s default gateway is router R3, and router R3 has received three default routes. Which one does it use?
Router R3’s path selection depends on the dynamic routing protocol being used. As you will see later in this chapter, a routing protocol such as Routing Information Protocol (RIP) would make the path selection based on the number of routers that must be used to reach the Internet (that is, hop count). Based on the topology presented, router R3 would select the 128Kbps link (where Kbps stands for kilobits per second, meaning thousands of bits per second) connecting to router R2 because the Internet would be only one hop away. If router R3 instead selected a path pointing to either router R1 or R4, the Internet would be two hops away.
However, based on the link bandwidths, you can see that the path from router R3 to router R2 is suboptimal. Unfortunately, RIP does not consider available bandwidth when making its route selection. Some other protocols, such as Open Shortest Path First (OSPF), can consider available bandwidth when making their routing decisions.
Dynamic routes also allow a router to reroute around a failed link. For example, in Figure 10-8, router R3 prefers to reach the Internet via router R4. However, the link between routers R3 and R4 goes down. Thanks to a dynamic routing protocol, router R3 knows of two other paths to reach the Internet, and it selects the next-best path, which is via router R1 in this example. This process of failing over from one route to a backup route is called convergence.
FIGURE 10-8 Route Redundancy
Routing Protocol Characteristics
Before examining the characteristics of routing protocols, we need to look at the important distinction between a routing protocol and a routed protocol:
A routing protocol (for example, RIP, OSPF, or EIGRP) is a protocol that advertises route information between routers.
A routed protocol is a protocol with an addressing scheme (for example, IP) that defines different network addresses. Traffic can then be routed between defined networks, perhaps with the assistance of a routing protocol.
This section looks at routing protocol characteristics, such as how believable a routing protocol is compared to other routing protocols. In addition, in the presence of multiple routes, different routing protocols use different metrics to determine the best path. A distinction is made between interior gateway protocols (IGPs) and exterior gateway protocols (EGPs). Finally, this section discusses different approaches to making route advertisements.
Believability of a Route
If a network is running more than one routing protocol (maybe as a result of a corporate merger), and a router receives two route advertisements from different routing protocols for the same network, which route advertisement does the router believe? Interestingly, some routing protocols are considered to be more believable that others. For example, a Cisco router would consider EIGRP to be more believable than RIP.
The index of believability is called administrative distance (AD). Table 10-1 shows the AD values for various sources of routing information. Note that lower AD values are more believable than higher AD values.
Table 10-1 Administrative Distance
Routing Information Source |
AD Value |
---|---|
Directly connected network |
0 |
Statically configured network |
1 |
EIGRP |
90 |
OSPF |
110 |
RIP |
120 |
External EIGRP |
170 |
Unknown or unbelievable |
255 (considered to be unreachable) |
Metrics
Some networks might be reachable via more than one path. If a routing protocol knows of multiple paths to reach such a network, which route (or routes) does the routing protocol select? Actually, it varies depending on the routing protocol and what that routing protocol uses as a metric (that is, a value assigned to a route). Lower metrics are preferred over higher metrics.
Some routing protocols support load balancing across equal-cost paths; this is useful when a routing protocol knows of more than one route to reach a destination network and those routes have equal metrics. EIGRP can even be configured to do load balancing across unequal-cost paths.
Different routing protocols can use different parameters in their calculation of a metric. The specific parameters used for a variety of routing protocols are presented later in this chapter.
Interior Versus Exterior Gateway Protocols
Routing protocols can also be categorized based on the scope of their operation. Interior gateway protocols (IGPs) operate within an autonomous system, where an autonomous system is a network under a single administrative control. Conversely, exterior gateway protocols (EGPs) operate between autonomous systems.
Consider Figure 10-9. Routers R1 and R2 are in one autonomous system (AS 65002), and routers R3 and R4 are in another autonomous system (AS 65003). Within those autonomous systems, an IGP is used to exchange routing information. However, router ISP1 is a router in a separate autonomous system (AS 65001) that is run by a service provider. An EGP (typically, Border Gateway Protocol) is used to exchange routing information between the service provider’s autonomous system and each of the other autonomous systems.
Route Advertisement Method
Another characteristic of a routing protocol is how it receives, advertises, and stores routing information. The two fundamental approaches are distance vector and link state.
FIGURE 10-9 IGPs Versus EGPs
Distance Vector
A distance-vector routing protocol sends a full copy of its routing table to its directly attached neighbors. This is a periodic advertisement, meaning that even if there have been no topological changes, a distance-vector routing protocol will, at regular intervals, advertise again its full routing table to its neighbors.
Obviously, this periodic advertisement of redundant information is inefficient. Ideally, you want a full exchange of route information to occur only once and subsequent updates to be triggered by topological changes.
Another drawback to distance-vector routing protocols is the time they take to converge, which is the time required for all routers to update their routing tables in response to a topological change in a network. Hold-down timers can speed the convergence process. After a router makes a change to a route entry, a hold-down timer prevents any subsequent updates for a specified period of time. This approach helps stop flapping routes (which are routes that oscillate between being available and unavailable) from preventing convergence.
Yet another issue with distance-vector routing protocols is the potential of a routing loop. To illustrate, consider Figure 10-10. In this topology, the metric being used is hop count, which is the number of routers that must be crossed to reach a network. As one example, router R3’s routing table has a route entry for network 10.1.1.0/24 available off router R1. For router R3 to reach that network, two routers must be transited (routers R2 and R1). As a result, network 10.1.1.0/24 appears in router R3’s routing table with a metric (hop count) of 2.
FIGURE 10-10 Routing Loop: Before Link Failure
Continuing with the example, imagine that interface Ethernet 1/0 on router R3 goes down. As shown in Figure 10-11, router R3 loses its directly connected route (with a metric of 0) to network 10.1.4.0/24. However, router R2 had a route to 10.1.4.0/24 in its routing table (with a metric of 1), and this route was advertised to router R3. Router R3 adds this entry for 10.1.4.0 to its routing table and increments the metric by 1.
FIGURE 10-11 Routing Loop: After Link Failure
The problem with this scenario is that the 10.1.4.0/24 entry in router R2’s routing table was due to an advertisement router R2 received from router R3. Now, router R3 is relying on that route, which is no longer valid. The routing loop continues as router R3 advertises its newly learned route 10.1.4.0/24 with a metric of 2 to its neighbor, router R2. Because router R2 originally learned the 10.1.4.0/24 network from router R3, when it sees router R2 advertising that same route with a metric of 2, the network gets updated in router R2’s routing table to have a metric of 3, as shown in Figure 10-12.
FIGURE 10-12 Routing Loop: Routers R2 and R3 Incrementing the Metric for 10.1.4.0/24
The metric for the 10.1.4.0/24 network continues to increment in the routing tables for both routers R2 and R3 until the metric reaches a value considered to be an unreachable value (for example, 16 in the case of RIP). This process is referred to as a routing loop.
Distance-vector routing protocols typically use one of two approaches for preventing routing loops:
Split horizon: The split-horizon feature prevents a route learned on one interface from being advertised back out that same interface.
Poison reverse: The poison-reverse feature causes a route received on one interface to be advertised back out that same interface with a metric that is considered to be infinite.
In the previous example, either approach would have prevented router R3 from adding the 10.1.4.0/24 network to its routing table based on an advertisement from router R2.
Link State
Rather than having neighboring routers exchange their full routing tables with one another, a link-state routing protocol allows routers to build a topological map of the network. Then, much like a Global Positioning System (GPS) device in a car, a router can execute an algorithm to calculate an optimal path (or paths) to a destination network.
Routers send link-state advertisements (LSAs) to advertise the networks they know how to reach. Routers then use those LSAs to construct the topological map of a network. The algorithm that runs against this topological map is Dijkstra’s shortest path first algorithm.
Unlike distance-vector routing protocols, link-state routing protocols exchange full routing information only when two routers initially form their adjacency. Then routing updates are sent in response to changes in the network, as opposed to being sent periodically. Also, link-state routing protocols benefit from shorter convergence times compared to distance-vector routing protocols.
Routing Protocol Examples
Now that you understand some of the characteristics that distinguish one routing protocol from another, this section contrasts some of the most popular routing protocols used in modern networks:
Routing Information Protocol (RIP): RIP is a distance-vector routing protocol that uses the metric hop count. The maximum number of hops between two routers in an RIP-based network is 15. Therefore, a hop count of 16 is considered to be infinite. Also, RIP is an IGP.
Open Shortest Path First (OSPF): OSPF is a link-state routing protocol that uses the metric cost, which is based on the link speed between two routers. OSPF is a popular IGP because of its scalability, fast convergence, and vendor interoperability.
Intermediate System-to-Intermediate System (IS-IS): This link-state routing protocol is similar in operation to OSPF. It uses a configurable, yet dimensionless, metric associated with an interface and runs Dijkstra’s shortest path first algorithm. Although IS-IS is an IGP that offers the scalability, fast convergence, and vendor-interoperability benefits of OSPF, it has not been as widely deployed as OSPF.
Enhanced Interior Gateway Routing Protocol (EIGRP): EIGRP is a Cisco-proprietary protocol that is popular in Cisco-only networks but less popular in mixed-vendor environments. Like OSPF, EIGRP is an IGP that offers fast convergence and scalability. EIGRP is more challenging to classify as a distance-vector or a link-state routing protocol.
By default, EIGRP uses bandwidth and delay in its metric calculation; however, other parameters can be considered, including reliability, load, and maximum transmission unit (MTU) size. Using delay as part of the metric, EIGRP can take into consideration the latency caused by the slowest links in the path.
Some literature calls EIGRP an advanced distance-vector routing protocol, and some literature calls it a hybrid routing protocol (mixing characteristics of both distance-vector and link-state routing protocols). EIGRP uses information from its neighbors to help select an optimal route (like distance-vector routing protocols). However, EIGRP also maintains a database of topological information (like a link-state routing protocol). The algorithm EIGRP uses for its route selection is not Dijkstra’s shortest path first algorithm. Instead, EIGRP uses Diffusing Update Algorithm (DUAL).
Border Gateway Protocol (BGP): BGP is the only EGP in widespread use today. In fact, BGP is considered to be the routing protocol that runs the Internet, which is an interconnection of multiple autonomous systems. Although some literature classifies BGP as a distance-vector routing protocol, it can more accurately be described as a path-vector routing protocol, meaning that it can use as its metric the number of autonomous system hops that must be transited to reach a destination network, as opposed to a number of required router hops. BGP’s path selection is not solely based on autonomous system hops, however. BGP can consider a variety of other parameters. Interestingly, none of those parameters are based on link speed. In addition, although BGP is incredibly scalable, it does not quickly converge in the event of a topological change.
Table 10-2 compares the key characteristics of dynamic routing protocols.
Table 10-2 Comparing Dynamic Routing Protocols
Routing Protocol |
IGP or EGP |
Type |
Metric |
---|---|---|---|
RIP |
IGP |
Distance vector |
Hop count |
OSPF |
IGP |
Link state |
Cost (based on bandwidth) |
EIGRP |
IGP |
Hybrid |
Composite (bandwidth and delay by default) |
BGP |
EGP |
Path vector |
Path attributes |
A network can simultaneously support more than one routing protocol through the process of route redistribution. For example, a router could have one of its interfaces participating in an OSPF area of the network and have another interface participating in an EIGRP area of the network. This router could then take routes learned via OSPF and inject those routes into the EIGRP routing process. Similarly, EIGRP-learned routes could be redistributed into the OSPF routing process.
Bandwidth Management
While the main concern with routing is ensuring that data packets (as well as control plane packets) reach their rightful destinations, it is the job of quality of service (QoS) to ensure that packets do not suffer from long delays (latency) or, worse, dropped packets.
QoS is actually a suite of technologies that allows you to strategically optimize network performance for select traffic types. For example, in today’s converged networks (that is, networks simultaneously transporting voice, video, and data), some applications (for example, voice) might be more intolerant of delay (or latency) than other applications; for example, an FTP file transfer is less latency sensitive than a VoIP call. Fortunately, through the use of QoS technologies, you can identify which traffic types need to be sent first, how much bandwidth to allocate to various traffic types, which traffic types should be dropped first in the event of congestion, and how to make the most efficient use of the relatively limited bandwidth of an IP WAN. This section introduces QoS and a collection of QoS mechanisms.
Introduction to QoS
A lack of bandwidth is the overshadowing issue for most network quality problems. Specifically, when there is a lack of bandwidth, packets might suffer from one or more of the symptoms listed in Table 10-3.
Table 10-3 Three Categories of Quality Issues
Issue |
Description |
---|---|
Delay |
Delay is the time required for a packet to travel from source to destination. You might have witnessed delay on the evening news when the news anchor is talking via satellite to a foreign news correspondent. Because of the satellite delay, the conversation begins to feel unnatural. |
Jitter |
Jitter is the uneven arrival of packets. For example, imagine a VoIP conversation where packet 1 arrives at a destination router. Then, 20 ms later, packet 2 arrives. After another 70 ms, packet 3 arrives, and then packet 4 arrives 20 ms behind packet 3. This variation in arrival times (that is, variable delay) is not due to dropped packets, but the jitter might be interpreted by the listener as dropped packets. |
Drops |
Packet drops occur when a link is congested and a router’s interface queue overflows. Some types of traffic, such as UDP traffic carrying voice packets, are not retransmitted if packets are dropped. |
Fortunately, QoS features available on many routers and switches can recognize important traffic and then treat that traffic in a special way. For example, you might want to allocate 128Kbps of bandwidth for your VoIP traffic and give that traffic priority treatment.
Consider water flowing through a series of pipes with varying diameters. The water’s flow rate through those pipes is limited to the water’s flow rate through the pipe with the smallest diameter. Similarly, as a packet travels from source to destination, its effective bandwidth is the bandwidth of the slowest link along that path. For example, in Figure 10-13, notice that the slowest link speed is 256Kbps. This weakest link becomes the effective bandwidth between client and server.
Because the primary challenge of QoS is a lack of bandwidth, the logical question is, “How do we increase available bandwidth?” A knee-jerk response to that question is often “Add more bandwidth.” However, more bandwidth often comes at a relatively high cost.
FIGURE 10-13 Effective Bandwidth of 256Kbps
Think of your network as a highway system in a large city. During rush hour, the lanes of the highway are congested; during other periods of the day, the lanes might be underutilized. Instead of just building more lanes to accommodate peak traffic rates, the highway engineers might add a carpool lane to give higher priority to cars with two or more occupants. Similarly, you can use QoS features to give your mission-critical applications higher-priority treatment in times of network congestion.
QoS Configuration Steps
The mission statement of QoS could read something like this: “To categorize traffic and apply a policy to those traffic categories, in accordance with a QoS policy.” Understanding this underlying purpose of QoS can help you better understand the three basic steps involved in QoS configuration:
Step 1. Determine network performance requirements for various traffic types. For example, consider these design recommendations for voice, video, and data traffic:
Voice: No more than 150 ms of one-way delay; no more than 30 ms of jitter; and no more than 1% packet loss.
Video: No more than 150 ms of one-way delay for interactive voice applications (for example, video conferencing); no more than 30 ms of jitter; and no more than 1% of packet loss.
Data: Applications have varying delay and loss requirements. Therefore, data applications should be categorized into predefined classes of traffic, where each class is configured with specific delay and loss characteristics.
Step 2. Categorize traffic into specific categories. For example, you might have a category named Low Delay for voice and video packets in that category. You might also have a Low Priority class for traffic such as music downloads from the Internet.
Step 3. Document your QoS policy and make it available to your users. Then, for example, if users complain that their network gaming applications are running slowly, you can point them to your corporate QoS policy, which describes how applications such as network gaming have best-effort treatment, while VoIP traffic receives priority treatment.
The actual implementation of these steps varies based on the specific device you are configuring. In some cases, you might be using the command-line interface (CLI) of a router or switch. In other cases, you might have some sort of graphical user interface (GUI) through which you configure QoS on your routers and switches.
QoS Components
QoS features are categorized into one of the three categories shown in Table 10-4.
Table 10-4 Three Categories of QoS Mechanisms
Issue |
Description |
---|---|
Best effort |
Best-effort treatment of traffic does not truly provide QoS to that traffic because there is no reordering of packets. Best effort uses a first-in, first-out (FIFO) queuing strategy, where packets are emptied from a queue in the same order in which they entered the queue. |
Integrated Services (IntServ) |
IntServ is often referred to as hard QoS because it can make strict bandwidth reservations. IntServ uses signaling among network devices to provide bandwidth reservations. Resource Reservation Protocol (RSVP) is an example of an IntServ approach to QoS. Because IntServ must be configured on every router along a packet’s path, the main drawback of IntServ is its lack of scalability. |
Differentiated Services (DiffServ) |
DiffServ, as its name suggests, differentiates between multiple traffic flows. Specifically, packets are marked, and routers and switches can then make decisions (for example, dropping or forwarding decisions) based on those markings. Because DiffServ does not make an explicit reservation, it is often called soft QoS. Most modern QoS configurations are based on the DiffServ approach. |
Figure 10-14 summarizes these three QoS categories.
FIGURE 10-14 QoS Categories
QoS Mechanisms
As previously mentioned, a DiffServ approach to QoS marks traffic. However, for markings to impact the behavior of traffic, a QoS tool must reference those markings and alter the packets’ treatment based on them. The following is a collection of commonly used QoS mechanisms:
Classification
Marking
Congestion management
Congestion avoidance
Policing and shaping
Link efficiency
While all of these mechanisms can be considered important, this chapter focuses on the main bandwidth management tools policing and traffic shaping.
Policing and Traffic Shaping
Instead of making a minimum amount of bandwidth available for specific traffic types, you might want to limit available bandwidth. Both traffic policing and traffic shaping tools can accomplish this objective. Collectively, these tools are called traffic conditioners.
Policing can be used in either the inbound or the outbound direction, and it typically discards packets that exceed the configured rate limit, which you can think of as a speed limit for specific traffic types. Because policing drops packets, resulting in retransmissions, it is recommended for higher-speed interfaces.
Shaping buffers (and therefore delays) traffic exceeding a configured rate. Therefore, shaping is recommended for slower-speed interfaces.
Because traffic shaping (and policing) can limit the speed of packets exiting a router, a question arises: “How do you send traffic out of an interface at a rate that is less than the physical clock rate of the interface?” For this to be possible, shaping and policing tools do not transmit all the time. Specifically, they send a certain number of bits or bytes at line rate, and then they stop sending until a specific timing interval (for example, one-eighth of a second) is reached. After the timing interval is reached, the interface again sends a specific amount of traffic at the line rate. It stops and waits for the next timing interval to occur. This process continually repeats, allowing an interface to send an average bandwidth that might be below the physical speed of the interface. This average bandwidth is called the committed information rate (CIR). The number of bits (the unit of measure used with shaping tools) or bytes (the unit of measure used with policing tools) that is sent during a timing interval is called the committed burst (Bc). The timing interval is written as Tc.
For example, imagine that you have a physical line rate of 128Kbps, but the CIR is only 64Kbps. Also, assume that there are eight timing intervals in a second (that is, Tc = 1/8 second = 125 ms), and during each of those timing intervals, 8000 bits (the committed burst parameter) are sent at the line rate. Therefore, over the period of a second, 8000 bits are sent (at the line rate) eight times, for a grand total of 64,000 bits per second, which is the CIR. Figure 10-15 illustrates this shaping of traffic to 64Kbps on a line with a rate of 128Kbps.
FIGURE 10-15 Traffic Shaping
If all the Bc bits (or bytes) are not sent during a timing interval, there is an option to bank those bits and use them during a future timing interval. The parameter that allows this storing of unused potential bandwidth is called the excess burst (Be) parameter. The Be parameter in a shaping configuration specifies the maximum number of bits or bytes that can be sent in excess of the Bc during a timing interval, if those bits are indeed available. For those bits or bytes to be available, they must have gone unused during previous timing intervals. Policing tools, however, use the Be parameter to specify the maximum number of bytes that can be sent during a timing interval. Therefore, in a policing configuration, if the Bc equals the Be, no excess bursting occurs. If excess bursting occurs, policing tools consider this excess traffic to be exceeding traffic. Policing tools consider traffic that conforms to (that is, does not exceed) a specified CIR to be conforming traffic.
The relationship between the Tc, Bc, and CIR is given with this formula: CIR = Bc / Tc. Alternatively, the formula can be written as Tc = Bc / CIR. Therefore, if you want a smaller timing interval, you can configure a smaller Bc.
Real-World Case Study
Acme, Inc. has decided to use a link-state routing protocol for dynamic routing between its LANs and the remote offices, which are connected over the WANs. The link-state protocol the company has chosen is OSPF. Each of the routers that has connections to the LAN and WAN subnets will learn about and advertise OSPF routes with its OSPF neighbors.
The branch offices will have a default route that points toward the headquarters’ routers, and at the headquarters’ site, they will use a default route that points toward the service provider. Acme, Inc. itself will not be using BGP, but its WAN and Internet service provider, which is interacting with other service providers, will use BGP.
The WAN connection to one of the remote offices is very low bandwidth and is prone to becoming congested with traffic. It also occasionally drops all connection to the remote office’s router. Acme, Inc., has decided to use traffic shaping as part of the QoS configuration to attempt to ensure that the link is used more sparingly and is not overwhelmed with traffic during key business hours.
Summary
Here are the main topics covered in this chapter:
This chapter discusses how routers forward traffic through a network based on source and destination IP addresses.
This chapter also covers the sources of route information used to populate a router’s routing table. These sources include directly connected routes, statically configured routes, and dynamically learned routes.
This chapter distinguishes between routed protocols (for example, IP) and routing protocols (such as OSPF or EIGRP).
Some routing sources are more trustworthy than other routing sources, based on their administrative distances.
Different routing protocols use different metrics to select the best route in the presence of multiple routes.
This chapter distinguishes between IGPs (which run within an autonomous system) and EGPs (which run between autonomous systems).
This chapter contrasts the behavior of distance-vector and link-state routing protocols and shows how split horizon and poison reverse can prevent routing loops in a distance-vector routing protocol environment.
This chapter describes today’s most popular routing protocols (including RIP, OSPF, IS-IS, EIGRP, and BGP), along with their characteristics.
This chapter reviews various QoS technologies, with an emphasis on traffic shaping, which can limit the rate of data transmission on a WAN link to the CIR.
Review All the Key Topics
Review the most important topics from this chapter, noted with the Key Topic icon in the outer margin of the page. Table 10-5 lists these key topics and the page number where each is found.
Table 10-5 Key Topics for Chapter 10
Key Topic Element |
Description |
Page Number |
---|---|---|
Step list |
Basic routing process |
256 |
Table 10-1 |
Administrative distance |
263 |
IGPs versus EGPs |
265 |
|
List |
Preventing routing loops |
267 |
List |
Routing protocol examples |
268 |
Step list |
QoS configuration |
272 |
Table 10-4 |
Three categories of QoS mechanisms |
273 |
Section |
Limiting available bandwidth through traffic policing and traffic-shaping tools |
275 |
Complete Tables and Lists from Memory
Print a copy of Appendix C, “Memory Tables,” or at least the section for this chapter and complete as many of the tables as possible from memory. Appendix D, “Memory Tables Answer Key,” includes the completed tables and lists so you can check your work.
Define Key Terms
Define the following key terms from this chapter and check your answers in the Glossary:
Address Resolution Protocol (ARP)
Time-to-Live (TTL)
default static route
next-hop IP address
routed protocol
routing protocol
administrative distance (AD)
metric
interior gateway protocol (IGP)
exterior gateway protocol (EGP)
distance-vector routing protocol
link-state routing protocol
hold-down timer
split horizon
poison reverse
link-state advertisement (LSA)
Routing Information Protocol (RIP)
Open Shortest Path First (OSPF)
Enhanced Interior Gateway Routing Protocol (EIGRP)
Border Gateway Protocol (BGP)
route redistribution
quality of service (QoS)
traffic shaping
traffic policing
dynamic routing
hybrid routing protocol
Additional Resources
An OSPF Review: https://www.ajsnetworking.com/an-ospf-review/
EIGRP’s Composite Metric: https://www.ajsnetworking.com/eigrp-metric
Review Questions
The answers to these review questions appear in Appendix A, “Answers to Review Questions.”
If a PC on an Ethernet network attempts to communicate with a host on a different subnet, what destination IP address and destination MAC address will be placed in the packet/frame header sent by the PC?
Destination IP: IP address of the default gateway. Destination MAC: MAC address of the default gateway.
Destination IP: IP address of the remote host. Destination MAC: MAC address of the default gateway.
Destination IP: IP address of the remote host. Destination MAC: MAC address of the remote host.
Destination IP: IP address of the remote host. Destination MAC: MAC address of the local PC.
What protocol is used to request a MAC address that corresponds to a known IPv4 address on the local network?
IGMP
TTL
ICMP
ARP
What is the network address and subnet mask of a default route?
255.255.255.255/32
0.0.0.0/32
255.255.255.255/0
0.0.0.0/0
What routing protocol characteristic indicates the believability of the routing protocol (compared to other routing protocols)?
Weight
Metric
Administrative distance
SPF algorithm
Which of the following are distance-vector routing protocol features that can prevent routing loops? (Choose two.)
Reverse path forwarding (RPF) check
Split horizon
Poison reverse
Rendezvous point
Which of the following is a distance-vector routing protocol with a maximum usable hop count of 15?
BGP
EIGRP
RIP
OSPF
Which of the following routing protocols is an EGP?
BGP
EIGRP
RIP
OSPF
What is the term for unpredictable variation in delay in a modern network?
Congestion
Contention
Jitter
Serialization delay
The RSVP protocol is associated with which overall approach to QoS in a modern network?
DiffServ
IntServ
FIFO
Best effort
What QoS tool seeks to smooth out bandwidth utilization by buffering excess packets?
Traffic policing
Traffic shaping
Weighted Random Early Detection (WRED)
Integrated Services (IntServ)