Previous section   Next section

Recipe 7.8 Adjusting EIGRP Metrics

7.8.1 Problem

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

7.8.2 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)#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)#end
Router1#

7.8.3 Discussion

This command simply adds a constant value to the metrics of all of the 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,000Kbps. The delay command is measured in tens of microseconds, and can be anywhere between 1 and 16,777,215. 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 parameters with the show interface 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 1544Kbps (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.

We 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. 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 previously is the best way to achieve it.

You can see 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#

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

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

  Previous section   Next section
Top