Users Guide

Table Of Contents
BGP 1437
Configuring the Multi-Exit Discriminator in BGP Advertised Routes
The following example configures an egress routing policy that sets the metric
for matching routes. In the example, VLAN 10 is created, followed by an
access list matching directly connected source address 5.5.5.x for which the
metric will be injected into the advertised routes.
A route map “Inject-MED” is created. This route map sets the match criteria
as ACL MED-Hosts and configures the metric for matching routes to be 100.
Interface Gi1/0/1 is configured as a member of VLAN 10, VLAN 10 is assigned
an IP address, IP routing is enabled, and BGP router 65001 is created with a
router ID of 129.168.1.254. A static subnet route 129.168.0.X is created for
VLAN 10. An iBGP neighbor 129.168.0.254 is configured and the network
129.168.x.X is configured to inject the metric of 100 into routes matching the
prefix-list MED-Hosts. All other routes are permitted using the default
metric.
console#configure
console(config)#vlan 10
console(config-vlan)#exit
console(config)#ip prefix-list MED-Hosts seq 10 permit 5.5.5.0
255.255.255.0
console(config)#ip bgp-community new-format
console(config)#route-map “Inject-MED” permit 100
console(route-map)#match ip address prefix-list MED-Hosts
console(route-map)#set metric 100
console(route-map)#exit
console(config)#route-map “Inject-MED” permit 200
console(route-map)#exit
console(config)#interface gi1/0/1
console(config-if-Gi1/0/1)#switchport access vlan 10
console(config-if-Gi1/0/1)#exit
console(config)#interface vlan 10
console(config-if-vlan10)#ip address 129.168.10.2 /24
console(config-if-vlan10)#exit
console(config)#ip routing
console(config)#ip route 129.168.0.0 255.255.255.0 129.168.10.1
vlan 10
console(config)#router bgp 65001
console(config-router)#bgp router-id 129.168.1.254