BGP Large Communities (RFC 8092)
Understand BGP Large Communities -- the modern replacement for standard communities that supports 4-byte ASNs and richer signaling.
Why Large Communities?
Standard BGP communities are 32 bits: ASN:value where each field is 16 bits. This was designed when ASNs were 16-bit numbers (0-65535).
The problem: 4-byte ASNs (up to 4,294,967,295) cannot fit in the 16-bit ASN field of standard communities.
Standard community: ASN16:VALUE16 (4 bytes total)
Example: 65000:100
Large community: ASN32:VALUE32:VALUE32 (12 bytes total)
Example: 399999:100:200
Large Community Structure
A large community is a 12-byte value with three 32-bit fields:
+-----------------------------------+
| Global Administrator (32 bits) | -> Typically your ASN
+-----------------------------------+
| Local Data Part 1 (32 bits) | -> Function/category
+-----------------------------------+
| Local Data Part 2 (32 bits) | -> Value/parameter
+-----------------------------------+
The three fields are written as GA:LD1:LD2:
399999:1:100
| | |
| | +-- Value: local-pref 100
| +----- Function: set local-pref
+----------- ASN: 399999
Use Cases
Informational Tagging
# Tag routes by source type
399999:1:1 -- Learned from customer
399999:1:2 -- Learned from peer
399999:1:3 -- Learned from transit
399999:1:4 -- Originated internally
# Tag by geographic region
399999:2:840 -- Learned in US (ISO country code)
399999:2:276 -- Learned in Germany
399999:2:392 -- Learned in Japan
Action Communities (for customers)
# Set local-preference
399999:100:50 -- Set local-pref to 50
399999:100:100 -- Set local-pref to 100
399999:100:200 -- Set local-pref to 200
# Prepend to specific peers
399999:200:13335 -- Prepend 1x toward Cloudflare (AS 13335)
399999:201:13335 -- Prepend 2x toward Cloudflare
399999:202:13335 -- Prepend 3x toward Cloudflare
# Do not announce to specific peer
399999:300:32934 -- Do not announce to Facebook (AS 32934)
The extra field allows targeting specific remote ASes -- something impossible with standard communities.
Configuration Examples
# Cisco IOS-XR
route-policy SET-CUSTOMER-TAG
set large-community (399999:1:1)
end-policy
route-policy MATCH-CUSTOMER
if large-community matches-any (399999:1:1) then
set local-preference 200
endif
end-policy
# Junos
policy-statement TAG-CUSTOMER {
then {
community add CUSTOMER-LC;
}
}
community CUSTOMER-LC members [ large:399999:1:1 ];
# BIRD 2
function tag_customer() {
bgp_large_community.add((399999, 1, 1));
}
Migration from Standard Communities
You do not need to replace standard communities immediately. Run both in parallel:
- Define your large community scheme mirroring your standard community assignments.
- Add large communities to existing policy alongside standard ones.
- Publish documentation for both formats.
- Encourage peers to use large communities for new implementations.
- Deprecate standard communities once adoption is sufficient.
Adoption Status
Large communities are supported by all modern BGP implementations:
| Software | Support Since |
|---|---|
| Cisco IOS-XR | 6.1.2 (2017) |
| Junos | 17.1R1 (2017) |
| BIRD | 1.6.3 (2017) |
| FRRouting | 3.0 (2017) |
| OpenBGPd | 6.1 (2017) |
| GoBGP | 1.21 (2017) |
If you operate a 4-byte ASN, large communities are essential. Even with a 2-byte ASN, the richer three-field structure makes policy design cleaner and more expressive.