SDN frr.conf.local override question

kemeris

Member
Nov 23, 2021
27
1
8
46
Hello,

I am trying to override default rule route-map MAP_VTEP_OUT permit 1 by merging my frr.conf.local

frr.conf.local:
Code:
ip prefix-list C100001_ONLY_IPV4 seq 5 permit 10.0.20.0/24 le 32
ip prefix-list C100001_ONLY_IPV4 seq 10 deny 0.0.0.0/0 le 32
ipv6 prefix-list C100001_ONLY_IPV6 seq 5 permit 2001:1ab9:f002:2::4000/118 le 128
ipv6 prefix-list C100001_ONLY_IPV6 seq 10 deny ::/0 le 128
!
no route-map MAP_VTEP_OUT permit 1
!
route-map MAP_VTEP_OUT permit 1
 match ip address prefix-list C100001_ONLY_IPV4
exit
!
route-map MAP_VTEP_OUT permit 2
 match ipv6 address prefix-list C100001_ONLY_IPV6
exit
!

no matter what I try, default route map MAP_VTEP_OUT is always generated with priority 1, so my custom route maps does not work.
Any ideas how to override this route map?


final frr.conf:
Code:
!
ip prefix-list C100001_ONLY_IPV4 seq 10 deny 0.0.0.0/0 le 32
ip prefix-list C100001_ONLY_IPV4 seq 5 permit 10.0.20.0/24 le 32
!
ipv6 prefix-list C100001_ONLY_IPV6 seq 10 deny ::/0 le 128
ipv6 prefix-list C100001_ONLY_IPV6 seq 5 permit 2001:1ab9:f002:2::4000/118 le 128
!
route-map MAP_VTEP_IN permit 1
exit
!
route-map MAP_VTEP_OUT permit 1
exit
!
route-map MAP_VTEP_OUT permit 2
 match ip address prefix-list C100001_ONLY_IPV4
exit
!
route-map MAP_VTEP_OUT permit 3
 match ipv6 address prefix-list C100001_ONLY_IPV6
exit
!
 
Last edited:
Hi,
Unfortunately, this isn't currently possible due to how we designed the system. The issue is that we set the default route-maps with the lowest order number. Because these route-maps are immutable (they can't be changed due to how frr-reload works), the default one will always be selected and will accept everything. This means there's no way for you to override them with your own route-maps.

Ideally, we should have assigned the default route-maps a higher order number from the start (like we did with the fabrics). That would have allowed you to add your own route-map with a lower number to override the default behavior. Unfortunately, we can't change this now because it would break backward compatibility. If we changed the order numbers, existing users who have created route-maps (like route-map x permit 40) would be affected. Those route-maps don't do anything currently, but after the change, they would suddenly override the default route-map, which could cause unexpected problems.

We're currently looking into how we can overhaul the whole frr-config generation, which would entail allowing this behavior.

Thanks