The Journey of a Network Engineer

Dec 19 2010   3:46AM GMT

How to manipulate BGP Routes – part 3

Sulaiman Syed Profile: Sulaiman Syed

This is the last part of BGP route manipulation. As discussed in the earlier entries, routes can be manipulated by

  • neighbor distribute-list (standard ACL / extended ACL)
  • neighbor prefix-list
  • neighbor filter-list
  • neighbor route-map

A valid question before talking bout route-maps is, when to use a route-map? A general rule will be that when route manipulation is concerned with network prefixes, then neighbor distribute-list and prefix-list will suffice. filter-list will be used when route manipulation is based on AS information. route-maps should be used when the conditions are variable. They could be based on network prefixes, AS, next_hop, weight, local_pref, origin, MED, etc.

The following lines are the command line syntax for route-maps

neighbor neighbor-id route-map name {in | out}

route-map name {permit | deny} number

match ….

set

The match is the condition or conditions that we want to base our route manipulation on, while the set is the course of action we would like to take.

the following example shows how we can set the weight of 200 to routes advertised by a certain BGP neighbor (10.0.0.1) and the routes have ASN 55 in the AS PATH.

router bgp 111

neighbor 10.0.0.1 route-map weight-200 in

ip as-path access-list 5 permit _55_

route-map weight-200 permit 10

match as-path 5

set weight 200

route-map weight-200 permit 20

The second route map was necessary, without it all other routes advertised by neighbor 10.0.0.1 that don’t have ASN 55 will be removed.

This concludes the manipulation of BGP routes. :)

 Comment on this Post

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: