- RFC 1998
- Pre-stages inbound policy to
- match on communities
- set local pref
- set other attributes
- Results in outbound path selection.
The below routers are running in the following ASNs:
R1, R4 = ASN 200
R3, R2 = ASN 100
R4 is advertising its Loopback subnet of 220.127.116.11/24 into BGP. We’re going to change the Local Pref of the route 18.104.22.168 on R2 by using a community.
On R2 the configuration needs to first have communities setup:
These communities then need to be referenced in a Route Map, this one called ‘BGP_IN’.
This then needs to be applied to a neighbor statement. In this case with R1.
Next, we’ll add a prefix-list for R4’s loopback subnet.
Then a route-map called ‘BGP_OUT’.
This route-map will reference the Loopback subnet on R4 and set the community string to 100:110, which makes sense to R2.
Then the route-map will get applied to the neighbor statement towards R2.
Now on R2 we’re seeing that the local preference has changed in accordance with the route-map that sets values on communities.