Community Attribute

Communities provide a label to a set of prefixes that share one or more common properties. Upstream providers use the community label to apply routing policy using route-maps to the community member prefixes.

Route-maps support the community attribute for both match and set clauses. Use the set community route-map clause to label the route as a member of the specified community.

There are two means of specifying a community name:

One of the following actions must be specified:

This example shows how to append the community value 100:100 to BGP routes matching prefix list named permit100:

System(su)->configure
System(su-config)->route-map bgp bgprm1 permit
System(su-config-route-map-bgp)->match prefix-list permit100
System(su-config-route-map-bgp)->set community 100:100 set-specific
System(su-config-route-map-bgp)->

This example shows how to append the well-known NO_PEER community (RFC-3765) to BGP routes matching prefix list named permit200:

System(su)->configure
System(su-config)->route-map bgp bgprm1 permit
System(su-config-route-map-bgp)->match prefix-list permit200
System(su-config-route-map-bgp)->set community NO_PEER set-specific
System(su-config-route-map-bgp)->

The route-map match community clause provides the ability to set route policy for packets that have been set with community name matching the community name specified in the match clause.

This example shows how to match a packet community to community 100 in AS 121:

System(su)->configure
System(su-config)->route-map bgp bgprm1 permit
System(su-config-route-map-bgp)->match community 121:100
System(su-config-route-map-bgp)->