12-06-2022 08:49 AM - last edited on 12-06-2022 09:31 PM by Translator
Hi guys,
I try to attach an extended community to a prefix selected by its
next-hop
While this works perfectly with a
route-map
attached to a BGP neighbor, when trying to use it as an export map the router attaches the extended community to all prefixes in his BGP table. And thus the other vrf imports all of them.
As you can see in the attachment I tried it with a
nexthop-prefix-list
a
nexthop-access-list
and plain prefix-list to confirm.
Has anybody else had this problem and knows why it does not work? I know I could write a prefix-list with the prefixes themeselves instead of the next hop ip's. But this is a reallife problem with a growing list of static routes to be exported. So I'd like to avoid listing them all again. I could also set the ext community with the
route-map
at every route. But still I'm curious why I can't use this more elegant solution.
Many thanks,
Patrick
Solved! Go to Solution.
12-06-2022 09:27 AM - last edited on 12-06-2022 09:35 PM by Translator
Hi @pat.boehm ,
The only match condition supported in the context of the
export map
is "match ip address", hence the results you are seeing.
Regards,
12-06-2022 09:27 AM - last edited on 12-06-2022 09:35 PM by Translator
Hi @pat.boehm ,
The only match condition supported in the context of the
export map
is "match ip address", hence the results you are seeing.
Regards,
12-06-2022 09:46 AM
Hi Harold,
thanks for the quick reply. That's what I thought. But it was just a feeling. I couldn't find that restriction anywhere in the documentation. Where could I have found that information?
many thanks again,
Patrick
12-06-2022 11:01 AM
Hi @pat.boehm ,
I could find it in the IOS documentation either. I will report it to our documentation team.
Regards,
12-06-2022 09:42 AM
I will check export map match and set.
12-06-2022 10:10 AM - last edited on 12-06-2022 09:33 PM by Translator
solution I just think about,
first any prefix from specific neighbor will get special community,
then
using
export-map
instead match
next-hop
we will match community.
but I need time to do lab.
tonight is football match of Portugal, after it I will do lab and update you in both case if I success and if not.
12-06-2022 01:55 PM - last edited on 12-06-2022 09:34 PM by Translator
I do lab and success
i use community to tag any prefix from R2 and using
import-map
match this community to deny prefix.
please check below photo
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide