host1(config)#route-map nyc1 permit 10
host1(config-route-map)#set as-path prepend list list10
â– Use the no version to delete the set clause from a route map.
â– See set as-path prepend.
set comm-list delete
â– Use to remove communities specified by the community list from the community
attribute of routes matching the route map.
â– You can use this command to delete communities only if the community list
was created with a single community per list entry as shown in the following
sample configuration for router Test:
host1(config)#ip community-list 1 permit 231:10
host1(config)#ip community-list 1 permit 231:20
host1(config)#router bgp 45
host1(config-router)#neighbor 10.6.2.5 remote-as 5
host1(config-router)#neighbor 10.6.2.5 route-map indelete in
host1(config-router)#route-map indelete permit 10
host1(config-route-map)#set comm-list 1 delete
Router Test receives the same route from 10.6.2.5 and applies the indelete route
map. BGP compares each list entry with the community attribute. A match is
found for the list entry 231:10, and this community is deleted from the
community attribute. Similarly, a match is found for the list entry of 231:20, and
this community is deleted from the community attribute.
â– Use the no version to delete the set clause from a route map.
â– See set comm-list delete.
set community
â– Use to set the community attribute in BGP updates.
■You can specify a community list number in the range 1–4294967295, or in the
new community format of AA:NN, or one of the following well-known
communities:
■local-as—Prevents advertisement outside the local AS
■no-advertise—Prevents advertisement to any peer
■no-export—Prevents advertisement beyond the BGP confederation boundary
â– Alternatively, you can use the list keyword to specify the name of a community
list that you previously created with the ip community-list command.
â– Example
host1(config)#route-map nyc1 permit 10
host1(config-route-map)#set community no-advertise
â– Use the none keyword to remove the community attribute from a route.
Configuring BGP Routing Policy â– 77
Chapter 1: Configuring BGP Routing