BGP Communities Deep Reference
Cheat sheet · https://pcornel.dk/topic.php?topic=231
Answer
A BGP community is a tag attached to a route, written as AS:value (for example 65000:100). The tag does nothing by itself; routers act on it through policy — set LOCAL_PREF, filter or prepend when a tag is present. A few well-known communities, such as NO_EXPORT and NO_ADVERTISE, have a built-in meaning.
Remember
Cisco IOS does not send communities to a neighbour unless neighbor … send-community is configured. set community replaces all existing communities unless you add additive. ip bgp-community new-format shows them as AS:value. NO_EXPORT keeps a route inside the AS; NO_ADVERTISE stops it at the receiving router.
First checks
show ip bgp <prefix> → Community: line on the path. show ip community-list → what your policy matches. show route-map → the clause that sets or matches the community. show running-config | include send-community → is it sent at all.
Commands
ip community-list standard <name> permit <AA:NN>- Define a standard community match list.
match community <list-name>- Match a standard community list in a route map.
neighbor <peer> route-map <name> {in|out}- Attach BGP import or export policy in the chosen address family.
set community <AA:NN> additive- Add a standard community while preserving existing values.
set large-community <GA:LD1:LD2> additive- Add a 12-octet large community on supported IOS XE releases.
set local-preference <value>- Set AS-internal exit preference on routes selected by a route map.
show ip community-list- Inspect configured standard community-list entries.
neighbor <peer> send-community [standard|extended|both]- Enables transmission of selected community attribute types to a BGP peer.
ip bgp-community new-formatip community-list standard CUST permit 65000:100clear ip bgp <neighbor> soft in
Verify in this order
route-map sets the community (additive) → send-community toward the neighbour → neighbour receives the tag → community-list matches in its route-map → action (LOCAL_PREF, filter, prepend) → result in its BGP table
Where it usually breaks
underlay/interface reachability → protocol adjacency/session → received/originated state → policy → best path/RIB → FIB/adjacency → traffic path
BGP Communities Deep Reference operational reference
| Boundary | Known-good for BGP Communities Deep Reference | Suspicious signature | Next proof |
|---|---|---|---|
| Input/session | Correct peer, source, AF and route context | Session/source/input state disagrees | Exact peer/source/prefix detail |
| Policy/protocol | BGP communities as policy metadata carried with routes, including standard/well-known community handling, match/set policy, propagation to neighbors and the distinction between marking a route and proving the intended import/export action occurred matches intended design | the community is never set, the neighbor does not transmit the relevant community attribute, a community-list matches a different representation, route-map direction or sequence is wrong, a broad permit bypasses the intended action, or the community is correct but the operator assumes that alone proves export suppression or path preference | Compare policy/attributes/propagation |
| Route/forwarding | Expected result reaches RIB/FIB | Control-plane state exists but installed path disagrees | RIB/FIB/CEF + next-hop proof |
| Closure | Original workload passes for explained reason | Symptom moved, was bypassed or state was forced | Regression/failover test |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=231