cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
315
Views
1
Helpful
7
Replies

extended community

jay_7301
Level 1
Level 1

Hi All,

I'm trying to attach an extended community to a specific subnet learned from a CPE using the below config

however i don't see this community attached

ip prefix-list TEST_BGP_IN permit 192.168.1.0/24

route-map TEST_ROUTE_POLICY permit 5
match ip address prefix-list TEST_BGP_IN
set extcommunity rt 31655:2000 additive

router bgp 1
address-family ipv4 vrf INTERNET
neighbor 10.1.1.1 route-map TEST_ROUTE_POLICY in
end

Any help would be appreciated.

 

7 Replies 7

Neighbor x.x.x.x send-community both

MHM

jay_7301
Level 1
Level 1

This command is already in place. I was wondering if an extended community can be set on import or if we should be configuring an export-map?

Try clear ip bgp if you add this policy after bgp is established 

MHM

jay_7301
Level 1
Level 1

This has been done also

I run lab 
R3-R2 there is mpls VPNv4
R1 to R2 there is ebgp 
when I add route-map add rt additive with direction IN R2 not add RT 
but when I add route-map with direction out toward R3 it work as we need 

sorry it not work with IN direction 

MHM

Screenshot (927).png

Albertt
Level 1
Level 1

Can you try in following way? It should modify the route once is under vrf

route-map ADD_RT_IN permit 10
match ip address prefix-list TEST_BGP_IN
set extcommunity rt 31655:2000 additive

vrf definition INTERNET
rd 31655:100
route-target import 31655:2000
route-target export 31655:2000
address-family ipv4
import map ADD_RT_IN
exit-address-family

AshSe
VIP
VIP

Hello @jay_7301 

Based on the configuration you provided, it seems like you are trying to attach an extended community (route target) to a specific subnet learned from a CPE. However, the extended community is not being applied as expected. Here are some troubleshooting steps and considerations to help resolve the issue:


1. Verify the Prefix is Being Matched

  • Ensure that the prefix 192.168.1.0/24 is actually being received from the neighbor 10.1.1.1.
  • Use the following command to check the received routes:
    show ip bgp vpnv4 vrf INTERNET neighbors 10.1.1.1 received-routes
    
    or, if you're working with IPv4 unicast:
    show ip bgp neighbors 10.1.1.1 received-routes
    
  • Confirm that the prefix 192.168.1.0/24 is present in the output.

2. Check the Prefix-List

  • Ensure that the prefix-list TEST_BGP_IN is correctly matching the prefix 192.168.1.0/24.
  • You can verify this by using the following command:
    show ip prefix-list TEST_BGP_IN
    
  • Confirm that the prefix 192.168.1.0/24 is permitted by the prefix-list.

3. Verify the Route-Map

  • Ensure that the route-map TEST_ROUTE_POLICY is being applied correctly and is matching the prefix.
  • You can use the following command to check the route-map:
    show route-map TEST_ROUTE_POLICY
    
  • Confirm that the route-map is configured to match the prefix-list and set the extended community.

4. Check the Extended Community Configuration

  • Ensure that the set extcommunity rt 31655:2000 additive command is correctly configured in the route-map.
  • The additive keyword ensures that the new extended community is added to any existing communities, rather than replacing them.

5. Verify the Neighbor Configuration

  • Ensure that the route-map TEST_ROUTE_POLICY is applied to the correct neighbor in the correct address family.
  • Use the following command to verify the neighbor configuration:
    show running-config | section router bgp
    
  • Confirm that the route-map is applied to the neighbor 10.1.1.1 under the address-family ipv4 vrf INTERNET.

6. Check for BGP Extended Community Support

  • Ensure that the device supports extended communities for the specific address family and VRF.
  • Some platforms or configurations may require additional commands to enable extended community support.

7. Verify the Result

  • After making the above checks, verify whether the extended community is being attached to the route.
  • Use the following command to check the BGP table for the VRF:
    show ip bgp vpnv4 vrf INTERNET
    
  • Look for the prefix 192.168.1.0/24 and check if the extended community 31655:2000is attached.

8. Debugging

  • If the issue persists, enable debugging to see if the route-map is being applied and if the extended community is being set:
    debug ip bgp updates
    
  • Monitor the logs for any errors or misconfigurations.

Common Issues to Check:

  1. Route-map sequence number: Ensure there are no conflicting entries in the route-map that might override the desired behavior.
  2. VRF configuration: Ensure that the VRF INTERNET is correctly configured and the neighbor is part of this VRF.
  3. BGP configuration: Ensure that the BGP session is established and the routes are being received.

If you still face issues after performing these checks, please provide additional details such as the output of the relevant show commands, and I can assist further!

 

Hope This Helps!!!

AshSe

Forum Tips: 

  1. Insert photos/images inline - don't attach.
  2. Always mark helpful and correct answers, it helps others find what they need.
  3. For a prompt reply, kindly tag @name. An email will be automatically sent to the member.