Implementing EIGRP

Implementing EIGRP

EIGRP is an advanced distance vector routing protocol developed by Cisco. EIGRP is suited for many different topologies and media. In a well-designed network, EIGRP scales well and provides extremely quick convergence times with minimal overhead. EIGRP is a popular choice for a routing protocol on Cisco devices.

Introducing EIGRP

EIGRP is a Cisco-proprietary routing protocol that combines the advantages of link-state and distance vector routing protocols. EIGRP is an advanced distance vector or hybrid routing protocol that includes the following features:

  • Rapid convergence: EIGRP uses the Diffusing Update Algorithm (DUAL) to achieve rapid convergence. A router that uses EIGRP stores all available backup routes for destinations so that it can quickly adapt to alternate routes. If no appropriate route or backup route exists in the local routing table, EIGRP queries its neighbors to discover an alternate route.
  • Reduced bandwidth usage: EIGRP does not make periodic updates. Instead, it sends partial updates when the path or the metric changes for that route. When path information changes, DUAL sends an update about only that link rather than about the entire table.
  • Multiple network layer support: EIGRP supports AppleTalk, IP version 4 (IPv4), IP version 6 (IPv6), and Novell Internetwork Packet Exchange (IPX), which use protocol-dependent modules (PDM). PDMs are responsible for protocol requirements that are specific to the network layer.
  • Classless routing: Because EIGRP is a classless routing protocol, it advertises a routing mask for each destination network. The routing mask feature enables EIGRP to support discontiguous subnetworks and variable-length subnet masks (VLSM).
  • Less overhead: EIGRP uses multicast and unicast rather than broadcast. As a result, end stations are unaffected by routing updates and requests for topology information.
  • Load balancing: EIGRP supports unequal metric load balancing, which allows administrators to better distribute traffic flow in their networks.
  • Easy summarization: EIGRP enables administrators to create summary routes anywhere within the network rather than rely on the traditional distance vector approach of performing classful route summarization only at major network boundaries.

Each EIGRP router maintains a neighbor table. This table includes a list of directly connected EIGRP routers that have an adjacency with this router.

Each EIGRP router maintains a topology table for each routed protocol configuration. The topology table includes route entries for every destination that the router learns. EIGRP chooses the best routes to a destination from the topology table and places these routes in the routing table, as illustrated in Figure 5-1.

Figure 5-1 EIGRP Tables
Implementing EIGRP fig5.1

In EIGRP, the best route is called a successor route while a backup route is called the feasible successor. To determine the best route (successor) and the backup route (feasible successor) to a destination, EIGRP uses the following two parameters:

  • Advertised distance: The EIGRP metric for an EIGRP neighbor to reach a particular network
  • Feasible distance: The advertised distance for a particular network learned from an EIGRP neighbor plus the EIGRP metric to reach that neighbor

A router compares all feasible distances to reach a specific network and then selects the lowest feasible distance and places it in the routing table. The feasible distance for the chosen route becomes the EIGRP routing metric to reach that network in the routing table.

The EIGRP topology database contains all the routes that are known to each EIGRP neighbor. Routers A and B send their routing tables to Router C, whose table is displayed in Figure 5-2. Both Routers A and B have pathways to network 10.1.1.0/24, as well as to other networks that are not shown.

Figure 5-2 Router C EIGRP Tables
Implementing EIGRP fig5.2

Router C has two entries to reach 10.1.1.0/24 in its topology table. The EIGRP metric for Router C to reach both Routers A and B is 1000. Add this cost (1000) to the respective advertised distance for each router, and the results represent the feasible distances that Router C must travel to reach network 10.1.1.0/24.

Router C chooses the least-cost feasible distance (2000) and installs it in the IP routing table as the best route to reach 10.1.1.0/24. The route with the least-cost feasible distance that is installed in the routing table is called the successor route.

Router C then chooses a backup route to the successor called a feasible successor route, if one exists. For a route to become a feasible successor, a next-hop router must have an advertised distance that is less than the feasible distance of the current successor route.

If the route through the successor becomes invalid, possibly because of a topology change, or if a neighbor changes the metric, DUAL checks for feasible successors to the destination route. If one is found, DUAL uses it, avoiding the need to recompute the route. If no feasible successor exists, a recomputation must occur to determine the new successor.

Configuring and Verifying EIGRP

Use the router eigrp and network commands to create an EIGRP routing process. Note that EIGRP requires an autonomous system (AS) number. The AS number does not have to be registered as is the case when routing on the Internet with the Border Gateway Protocol (BGP) routing protocol. However, all routers within an AS must use the same AS number to exchange routing information with each other. Figure 5-3 shows the EIGRP configuration of a simple network.

Figure 5-3 EIGRP Configuration
Implementing EIGRP fig5.3

The network command defines a major network number to which the router is directly connected.
The EIGRP routing process looks for interfaces that have an IP address that belongs to the networks that are specified with the network command and begins the EIGRP process on these interfaces.

Table 5-1 applies to the EIGRP configurations on Router A in the EIGRP configuration example.

Table 5-1 EIGRP Command Example
Implementing EIGRP tb5.1

EIGRP sends updates out of the interfaces in networks 10.0.0.0 and 172.16.0.0. The updates include information about networks 10.0.0.0 and 172.16.0.0 and any other networks that EIGRP learns.

EIGRP automatically summarizes routes at the classful boundary. In some cases, you might not want automatic summarization to occur. For example, if you have discontiguous networks, you need to disable automatic summarization to minimize router confusion. Figure 5-4 shows an example of how this summarization can cause advertisements for the 172.16.0.0 network to be sent from both Router A and Router B to Router C.

Figure 5-4 Autosummarization Causing Discontinuous Subnets
Implementing EIGRP fig5.4

To disable automatic summarization, use the no auto-summary command in the EIGRP router configuration mode. When this command is used, both Router A and Router B will advertise the route specific to the subnet of a given interface, as shown in Figure 5-5.

Figure 5-5 Disabling Autosummarization Corrects Problem
Implementing EIGRP fig5.5

After you enable EIGRP, various commands can be used to display information about how the protocol is operating. The show ip route eigrp command displays the current EIGRP entries in the routing table.

The show ip protocols command displays the parameters and current state of the active routing protocol process. This command shows the EIGRP AS number. It also displays filtering and redistribution numbers and neighbor and distance information. This also shows the networks that are currently being advertised on the router by the protocol.

Use the show ip eigrp interfaces [type number] [as-number] command to determine on which interfaces EIGRP is active, and to learn information about EIGRP that relates to those interfaces. If you specify an interface by using the type number option, only that interface is displayed. Otherwise, all interfaces on which EIGRP is running are displayed. If you specify an AS using the as-number option, only the routing process for the specified AS is displayed. Otherwise, all EIGRP processes are displayed. Example 5-1 shows the output of the show ip eigrp interfaces command.

Example 5-1 Determining Router Interface EIGRP Status/Information

Table 5-2 describes the significant fields generated by the show ip eigrp interfaces output.

Table 5-2 show ip eigrp interfaces Output
Implementing EIGRP tb5.2

Use the show ip eigrp neighbors command to display the neighbors that were discovered by EIGRP and to determine when neighbors become active and inactive, as demonstrated in Example 5-2. This command is also useful for debugging certain types of transport problems.

Example 5-2 Displaying Discovered Active/Inactive EIGRP Neighbors

Table 5-3 describes the significant fields for the show ip eigrp neighbors command.

Table 5-3 show ip eigrp neighbors Output
Implementing EIGRP tb5.3

The show ip eigrp topology command displays the EIGRP topology table, the active or passive state of routes, the number of successors, and the feasible distance to the destination, as demonstrated in Example 5-3.

Example 5-3 Displaying EIGRP Topology Information

Table 5-4 describes the significant fields for the show ip eigrp topology command output.

Table 5-4 show ip eigrp topology Output
Implementing EIGRP tb5.4

The show ip eigrp traffic command displays the number of packets sent and received, as demonstrated in Example 5-4.

Example 5-4 Displaying the Number of EIGRP Sent/Received Packets

Table 5-5 describes the fields that might be shown in the display

Table 5-5 show ip eigrp traffic Output
Implementing EIGRP tb5.5

The debug ip eigrp privileged EXEC command helps you analyze the EIGRP packets that an interface sends and receives, as demonstrated in Example 5-5. Because the debug ip eigrp command generates a substantial amount of output, use it only when traffic on the network is light.

Example 5-5 Analyzing Sent/Received EIGRP Packets

Table 5-6 describes the fields in the sample output from the debug ip eigrp command.

Table 5-6 debug ip eigrp Output
Implementing EIGRP tb5.6

Load Balancing with EIGRP

Typically, networks are configured with multiple paths to a remote network. When these paths are equal or nearly equal, it makes sense to utilize all the available paths. Unlike Layer 2 forwarding, Layer 3 forwarding has the capability to load-balance between multiple paths. That is, the router can send frames out multiple interfaces to reduce the amount of traffic sent to a single network connection. The key to this feature is that the network paths must be of equal cost (or nearly equal for some protocols like EIGRP). EIGRP uses a metric to compute the costs to a given network.

EIGRP Metric

The EIGRP metric can be based on several criteria, but EIGRP uses only two of these criteria by default:

  • Bandwidth: The smallest bandwidth between source and destination
  • Delay: The cumulative interface delay in microseconds along the path The following criteria can be used but are not recommended because they typically result in frequent recalculation of the topology table:
  • Reliability: This value represents the worst reliability between the source and destination, based on keepalives.
  • Load: This value represents the worst load on a link between the source and destination, computed based on the packet rate and the configured bandwidth of the interface.
NOTEAlthough the maximum transmission unit (MTU) is exchanged in EIGRP packets between neighbor routers, MTU is not factored into the EIGRP metric calculation.=

Load Balancing Across Equal Paths

Equal-cost load balancing is the capability of a router to distribute traffic over all its network ports that are the same metric from the destination address. Load balancing increases the use of network segments and increases effective network bandwidth.

For IP, Cisco IOS Software applies load balancing across up to four equal-cost paths by default. With the maximum-paths maximum-path router configuration command, up to 16 equal-cost routes can be kept in the routing table. If you set the maximum-path to 1, you disable load balancing. When a packet is process switched, load balancing over equal-cost paths occurs on a per-packet basis. When packets are fast switched, load balancing over equal-cost paths occurs on a per-destination basis.

NOTEIf you test load balancing, do not ping to or from routers that use fast-switching interfaces because these router-generated packets are process switched rather than fast switched and might produce confusing results.

Configuring Load Balancing Across Unequal-Cost Paths

EIGRP can also balance traffic across multiple routes that have different metrics, which is called unequal-cost load balancing. The degree to which EIGRP performs load balancing is controlled with the variance command.

The multiplier parameter for the variance command is a value from 1 to 128, used for load balancing. The default is 1, which indicates that only equal-cost load balancing is being performed. The multiplier defines the range of metric values that are accepted for load balancing by the EIGRP process.

NOTEBy default, traffic is distributed proportionately among the links with unequal costs, with respect to the metric.

Example: Variance

In Figure 5-6, a variance of 2 is configured, and the range of the metric values, which are the feasible distances for Router E to get to network 172.16.0.0, is 20 to 45. This range of values determines the feasibility of a potential route.

A route is feasible if the next router in the path is closer to the destination than to the current router and if the metric of the alternate path is within the variance. Load balancing can use only feasible paths, and the routing table includes only these paths. The two feasibility conditions are as follows:

Figure 5-6 Variance Example

Implementing EIGRP fig5.6

  • The local best metric, which is the current feasible distance, must be greater than the best metric (the advertised distance) that is learned from the next router. In other words, the next router in the path must be closer to the destination than to the current router; this criterion prevents routing loops.
  • The metric of the alternate path must be less than the variance multiplied by the local best metric (the current feasible distance).

If both of these conditions are met, the route is determined to be feasible and can be added to the routing table. In Figure 5-6, three paths to network 172.16.0.0 exist with the following metrics:

  • Path 1: 30 (through B)
  • Path 2: 20 (through C)
  • Path 3: 45 (through D)

By default, the router places only path 2 (through C) in the routing table because it is the least-cost path. To load-balance over paths 1 and 2, use a variance of 2 because 20 * 2 = 40, which is greater than the metric through path 1.

In Figure 5-6, Router E uses Router C as the successor because it has the lowest feasible distance (20). With the variance 2 command applied to Router E, the path through Router B meets the criteria for load balancing. In this case, the feasible distance through Router B is less than twice the feasible distance for the successor (Router C).

Router D is not considered for load balancing with this variance because the feasible distance through Router D is greater than twice the feasible distance for the successor (Router C). In the example, however, Router D would never be a feasible successor no matter what the variance is. This decision is because the advertised distance of Router D is 25, which is greater than the Router E feasible distance of 20; therefore, to avoid a potential routing loop, Router D is not considered a feasible successor.

EIGRP Authentication

You can configure EIGRP neighbor authentication, also known as neighbor router authentication or route authentication, such that routers can participate in routing based on predefined passwords. By default, no authentication is used for EIGRP packets. EIGRP can be configured to use Message Digest Algorithm 5 (MD5) authentication.

When you configure neighbor authentication on a router, the router authenticates the source of each routing update packet that it receives. For EIGRP MD5 authentication, you must configure an authenticating key and a key ID on both the sending and the receiving router. The key is sometimes referred to as a password.

The MD5 keyed digest in each EIGRP packet prevents the introduction of unauthorized or false routing messages from unapproved sources.

Each key has its own key ID, which the router stores locally. The combination of the key ID and the interface that is associated with the message uniquely identifies the MD5 authentication key in use.

EIGRP enables you to manage keys by using key chains. Each key definition within the key chain can specify a time interval for which that key is activated (its lifetime). Then, during the lifetime of a given key, routing update packets are sent with this activated key. Only one authentication packet is sent, regardless of how many valid keys exist. The software examines the key numbers in order from lowest to highest, and it uses the first valid key that it encounters.

Keys cannot be used during time periods for which they are not activated. Therefore, it is recommended that for a given key chain, key activation times overlap to avoid any period of time for which no key is activated. If a time exists during which no key is activated, neighbor authentication cannot occur, and therefore, routing updates fail.

NOTEThe routers must know the correct time to rotate through keys in synchronization with the other participating routers. This ensures that all the routers are using the same key at the same moment.

Creating a Key Chain

Perform the following steps to create a key chain:
Step 1 Enter the key chain command to enter the configuration mode for the key chain. The value provided for the name-of-chain parameter for the key chain command indicates the name of the authentication key chain from which a key is to be obtained.

Step 2 Use the key command to identify a key ID to use, and enter configuration mode for that key. The value provided for the key-id parameter of the key command indicates the ID number of an authentication key on a key chain. The range of keys is from 0 to 2147483647. The key ID numbers need not be consecutive.

Step 3 Use the key-string command to identify the key string (password) for this key. The value provided for the text parameter of the key-string command indicates the authentication string that is to be used to authenticate sent and received EIGRP packets. The string can contain from 1 to 80 uppercase and lowercase alphanumeric characters. The first character cannot be a number, and the string is case sensitive.

Step 4 Optionally, use accept-lifetime to specify the time during which this key is accepted for use on received packets. If you do not enter an accept-lifetime command, the time is infinite. Table 5-7 describes the accept-lifetime command parameters.

Table 5-7 accept-lifetime Parameters
Implementing EIGRP tb5.7

Step 5 Optionally, specify the time during which this key can be used for sending
packets using the send-lifetime command. If you do not enter a sendlifetime command, the time is infinite. Table 5-8 describes the sendlifetime command parameters.

Table 5-8 send-lifetime Parameters
Implementing EIGRP tb5.8

NOTE If the service password-encryption command is not used when you are implementing EIGRP authentication, the key string is stored as plain text in the router configuration. If you configure the service password-encryption command, the key string is stored and displayed in an encrypted form; when it is displayed, an encryption type of 7 is specified before the encrypted key string.

Configuring MD5 Authentication for EIGRP

To configure MD5 authentication for EIGRP, complete the following steps:
Step 1 Enter configuration mode for the interface on which you want to enable authentication.
Step 2 Use the ip authentication mode eigrp autonomous-system md5 command to specify that MD5 authentication is to be used for EIGRP packets. The value provided for the autonomous-system parameter of the ip authentication mode eigrp md5 command indicates the EIGRP AS number in which authentication is to be used.
Step 3 Use the ip authentication key-chain eigrp autonomous-system name-ofchain command to specify which key chain to use for the authentication of EIGRP packets. Table 5-9 describes the parameters for this command.

Table 5-9 ip authentication key-chain eigrp Parameters
Implementing EIGRP tb5.9

Example: MD5 Authentication Configuration

Figure 5-7 shows an example network used for the configuration of EIGRP MD5 authentication for Router X in Example 5-6.

Figure 5-7 Network Topology for EIGRP MD5 Configuration Example
Implementing EIGRP fig5.7

Example 5-6 Configuring EIGRP MD5 Authentication on Router X

MD5 authentication is configured on the Serial 0/0/1 interface with the ip authentication mode eigrp 100 md5 command. The ip authentication key-chain eigrp 100 RouterXchain command specifies that the key chain RouterXchain is to be used for EIGRP AS 100.

The key chain RouterXchain command enters configuration mode for the RouterXchain key chain. Two keys are defined. Key 1 is set to “first key” with the key-string firstkey command. This key is acceptable for use on packets that are received by Router X from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the accept-lifetime 04:00:00 Jan 1 2006 infinite command. However, the send-lifetime 04:00:00 Jan 1 2006 04:01:00 Jan 1 2006 command specifies that this key is valid for use only when packets are sent for one minute on January 1, 2006; afterward, it is no longer valid for use in sending packets.

Key 2 is set to “second key” with the key-string secondkey command. This key is acceptable for use on packets that are received by Router X from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the accept-lifetime 04:00:00 Jan 1 2006 infinite command. This key can also be used when packets are sent from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the send-lifetime 04:00:00 Jan 1 2006 infinite command.

Therefore, Router X accepts and attempts to verify the MD5 digest of any EIGRP packets with a key ID equal to 1. Router X will also accept a packet with a key ID equal to 2. All other MD5 packets are dropped. Router X sends all EIGRP packets using key 2 because key 1 is no longer valid for use in sending packets.
Example 5-7 shows the configuration of EIGRP MD5 authentication for Router Y in Figure 5-7.

Example 5-7 Configuring EIGRP MD5 Authentication on Router Y

MD5 authentication is configured on the Serial 0/0/1 interface with the ip authentication mode eigrp 100 md5 command. The ip authentication key-chain eigrp 100 RouterYchain command specifies that the key chain RouterYchain is to be used for EIGRP AS 100.

The key chain RouterYchain command enters configuration mode for the RouterYchain key chain. Two keys are defined. Key 1 is set to “first key” with the key-string firstkey command. This key is acceptable for use on packets that are received by Router Y from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the accept-lifetime 04:00:00 Jan 1 2006 infinite command. This key can also be used when packets are sent from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the send-lifetime 04:00:00 Jan 1 2006 infinite command.

Key 2 is set to “second key” with the key-string secondkey command. This key is acceptable for use on packets that are received by Router Y from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the accept-lifetime 04:00:00 Jan 1 2006 infinite command. This key can also be used when packets are sent from 4:00 a.m. (0400) on January 1, 2006, onward, as specified in the send-lifetime 04:00:00 Jan 1 2006 infinite command.

Therefore, Router Y accepts and attempts to verify the MD5 digest of any EIGRP packets with a key ID equal to 1 or 2. Router Y uses key 1 to send all EIGRP packets because it is the first valid key in the key chain.

Verifying MD5 Authentication

Example 5-8 shows the output of the show ip eigrp neighbors and show ip route commands on Router X.

Example 5-8 Verifying EIGRP MD5 Authentication on Router X

The fact that the neighbor table shows the IP address of Router Y indicates that the two routers have successfully formed an EIGRP adjacency. The routing table verifies that the 172.17.0.0 network has been learned through EIGRP over the serial connection. Therefore, the MD5 authentication for EIGRP must have been successful between Router X and Router Y.

The results of a ping to the Router Y FastEthernet interface address are also displayed to illustrate that the link is working.

More Resources

About the author

Prasanna

Leave a Comment