This section describes the rules for route selection among EVPN-IFL, VPN-IP, and IP route table owners.
A PE may receive an IPv4 or IPv6 prefix in routes from different or same owners, and from the same or different BGP peer. For example, prefix 10.0.0.0/24 can be received as an EVPN-IFL route and also received as a VPN-IPv4 route. Or prefix 2001:db8:1::/64 can be received in two EVPN-IFL routes with different route distinguishers from different peers. In all these examples, the router selects the best route in a deterministic way.
For EVPN-IFF route selection rules, see Route selection for EVPN-IFF routes in the VPRN service. In SRĀ OS, the VPRN route table route selection for all BGP routes, excluding EVPN-IFF, is performed using the following ordered, tie-breaking rules:
valid route wins over invalid route
lowest origin validation state (valid<not found<invalid) wins
lowest RTM (route table) preference wins
highest local preference wins
shortest D-PATH wins (skipped if d-path-length-ignore is configured)
lowest AIGP metric wins
shortest AS_PATH wins (skipped if the as-path-ignore command is configured for the route owner)
lowest origin wins
lowest MED wins
lowest owner type wins (BGP<BGP-LABEL<BGP-VPN)
EBGP wins
lowest route table or tunnel-table cost to the next hop (skipped if the ignore-nh-metric command is configured)
lowest next-hop type wins (resolution of next hop in TTM wins vs RTM) (skipped if the ignore-nh-metric command is configured)
lowest router ID wins (skipped if the ignore-router-id command is configured)
shortest cluster_list length wins
lowest IP address
EVPN-IFL wins over IPVPN routes
next-hop check (IPv4 next hop wins over IPv6 next hop, and then lowest next hop wins)
RD check for RTM (lowest RD wins)
ECMP is not supported across EVPN-IFL and other owners, but it is supported within the EVPN-IFL owner for multiple EVPN-IFL routes received with the same IP prefix. When ECMP is configured with N number of paths in the VPRN, BGP orders the routes based on the previously described tie-break criteria breaking out after step13 (lowest next-hop type). At that point, BGP creates an ECMP set with the best N routes.
Example:
In a scenario in which two EVPN-IFL routes are received on the same VPRN with same prefix, 10.0.0.0/24; different RDs 192.0.2.1:1 and 192.0.2.2; and different router ID, 192.0.2.1 and 192.0.2.2; the following tie-breaking criteria are considered.
Assuming everything else is the same, BGP orders the routes based on the preceding criteria and prefers the route with the lowest router ID.
If vprn>ecmp=2, the two routes are treated as equal in the route table and added to the same ECMP set.