Adjusting EIGRP Metrics

Problem

You want to modify the routing metrics for routes learned via EIGRP.

Solution

You can use the offset-list configuration command to modify the metrics of routes that EIGRP learns through a particular interface:

Router1#configure terminal 
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#access-list 22 permit 192.168.30.0
Router1(config)#router eigrp 55
Router1(config-router)#offset-list 22 in 10000 Serial0.1
Router1(config-router)#exit
Router1(config)#end
Router1#

This command can also modify the EIGRP metrics of routes as the router sends them out through an interface:

Router1#configure terminal 
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#access-list 33 permit 192.168.30.0
Router1(config)#router eigrp 55
Router1(config-router)#offset-list 33 out 10000 Serial0.1
Router1(config-router)#exit
Router1(config)#end
Router1#

 

Discussion

The offset-list command simply adds a constant value to the metrics of all routes that are either sent or received through a particular interface. There are actually two other ways to modify metrics in EIGRP. Recall that the EIGRP metric is a combination of the aggregate delay and the minimum bandwidth along a path. So instead of adding an offset to the entire metric, you can modify the bandwidth and delay separately as follows:

Router1(config)#interface Serial0.1
Router1(config-if)#bandwidth 56
Router1(config-if)#delay 1000

The bandwidth command takes an argument in kilobits per second, and will accept a value between 1 and 10,000,000 kbps. The delay command is measured in tens of microseconds, and can be anywhere between 1 and 16,777,215. So, in this case, we have specified a value of 1000, meaning a delay of 10,000 microseconds (10 milliseconds). You can see the current values for both of these values with the show interfaces command:

Router1#show interfaces serial0.1
Serial0.1 is up, line protocol is up 
 Hardware is HD64570
 Internet address is 172.25.2.2/30
 MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, 
 reliability 255/255, txload 1/255, rxload 1/255
 Encapsulation FRAME-RELAY
Router1#

In this example, subinterface Serial0.1 has the default values for a serial interface, a bandwidth of 1544 kbps (a T1), and a delay of 20,000 microseconds (20 milliseconds). It is always a good idea to check the current values before adjusting either the bandwidth or delay parameters, if only to make sure that you are moving them in the right direction.

However, we would offer one important caution on adjusting the bandwidth parameter, in particular. This same value also appears in the SNMP variable ifSpeed for this interface. This is often used by performance management software to define the total available bandwidth for the interface. So changing this number to fix an EIGRP issue might cause a problem for your performance management system.

One of the problems with adjusting the delay and bandwidth on the interface is that you can't use this to separately adjust inbound and outbound routing metrics. If you need this level of control, the offset-list method discussed above is the best way to achieve it.

You can see the effect of an offset list in the output of the show ip protocols command:

Router1#show ip protocols 
Routing Protocol is "eigrp 55"
 Outgoing update filter list for all interfaces is not set
 Incoming update filter list for all interfaces is not set
 Serial0.1 filtered by (prefix-list) Inbound
 Incoming routes in Serial0.1 will have 10000 added to metric if on list 22
 Default networks flagged in outgoing updates
 Default networks not accepted from incoming updates
 EIGRP metric weight K1=1, K2=0, K3=1, K4=0, K5=0
 EIGRP maximum hopcount 100
 EIGRP maximum metric variance 1
 Redistributing: static, eigrp 55
 Automatic network summarization is in effect
 Automatic address summarization:
 192.168.20.0/24 for Loopback0, Serial0.1
 172.25.0.0/16 for Ethernet0
 Summarizing with metric 128256
 Maximum path: 4
 Routing for Networks:
 172.25.0.0
 192.168.20.0
 Routing Information Sources:
 Gateway Distance Last Update
 172.25.2.1 90 00:02:09
 Distance: internal 90 external 170
Router1#

And you can also see the difference it makes by looking at the routing tables. In this case, the route looked like this before we applied the offset-list:

Router1#show ip route eigrp
D 192.168.30.0/24 [90/200416] via 172.25.2.1, 00:00:24, Serial0.1

And, as you can see, the metric has increased by 10,000 after applying the offset:

Router1#show ip route eigrp
D 192.168.30.0/24 [90/210416] via 172.25.2.1, 00:00:24, Serial0.1


Router Configuration and File Management

Router Management

User Access and Privilege Levels

TACACS+

IP Routing

RIP

EIGRP

OSPF

BGP

Frame Relay

Handling Queuing and Congestion

Tunnels and VPNs

Dial Backup

NTP and Time

DLSw

Router Interfaces and Media

Simple Network Management Protocol

Logging

Access-Lists

DHCP

NAT

First Hop Redundancy Protocols

IP Multicast

IP Mobility

IPv6

MPLS

Security

Appendix 1. External Software Packages

Appendix 2. IP Precedence, TOS, and DSCP Classifications

Index



Cisco IOS Cookbook
Cisco IOS Cookbook (Cookbooks (OReilly))
ISBN: 0596527225
EAN: 2147483647
Year: 2004
Pages: 505

Flylib.com © 2008-2020.
If you may any questions please contact us: flylib@qtcs.net