BGP Community Lists

A BGP community, as defined in RFC 1997, is a group of destinations which share common properties. Community Lists define sets of community attributes which the BGP daemon can use to match or set community values in routing updates. BGP communities determine AS membership and priority values in BGP-specific contexts such as route-maps.

BGP community lists are managed at Services > FRR BGP on the Communities tab.

The order of entries inside a community list is important, and this order is determined by a sequence number.

BGP Well-Known Communities

There are several “well-known” communities available for use in Community Lists. Each of these communities have special meanings:

internet:

A community value of 0, indicating the Internet as a destination.

no-export:

Routes received carrying this attribute value must not be exported to routers outside of the current confederation.

no-advertise:

Routes received carrying this attribute value must not be advertised to any other BGP peer.

local-as:

Also known as “No Export Subconfed”. Routes received carrying this attribute value must not be advertised to any external BGP peer, even those in the same confederation.

blackhole:

Routes received carrying this attribute should not be routed (e.g. null routed).

graceful-shutdown:

Indicates support for RFC 8326 Graceful Shutdown, which allows BGP routers to indicate to peers that specific paths can be gracefully shut down rather than abruptly terminated when performing an intentional shutdown.

no-peer:

Indicates that routes with this community value should not be readvertised to peers (RFC 3765).

BGP Community List Configuration

The Communities tab contains a list of current community lists, if any, and controls to manage the entires (e.g. edit, delete). The fa-plus Add button creates a new community list.

When creating or editing a community list, the following options are available:

Name:

The name of this BGP community list.

Description:

A text description of this list (e.g. its purpose)

Community List Type:

The type of community list to use for this entry, which controls how values are matched.

Standard:

Matches based on specific values for community attributes, either AS:Value pairs or names of well-known communities.

Expanded:

Matches based on an ordered list using a regular expression. Due to the use of regular expression evaluation, these lists incur a performance penalty.

Community List Entries:

A list of rules for this community list. Click fa-plus Add to create additional rules on the same list.

Sequence:

The sequence number for this rule, which controls the order in which rules are matched inside this community list. Each rule must have a unique sequence number. Best practice is to leave gaps in the sequence to allow for adding rules in the future. For example, use 10, 20, 30, rather than 1, 2, 3.

Action:

The action taken when this Community List rule is matched, either permit or deny.

Community:

The value of the community to match.

Standard Community Lists:

This is a space-separated list of communities in AS:Value format, or from the well-known communities list.

Expanded Community Lists:

A string containing a regular expression to match against.

Regular expression patterns support common pattern special characters for matching, but also a special _ character. The _ character matches common AS delimiters such as start of line, end of line, space, comma, braces, and parenthesis.