aristanetworks / avd

Arista Validated Designs
https://avd.arista.com
Apache License 2.0
290 stars 209 forks source link

Inband configuration defines a route-map but its not applied #4025

Closed dgonzalez85 closed 4 months ago

dgonzalez85 commented 5 months ago

Issue Summary

L2LS deployment, with leaves as L2 switches and Spines performing routing.

In the spines the following configuration is generated by AVD to allow the inband subnet:

route-map RM-CONN-2-BGP permit 20
   match ip address prefix-list PL-L2LEAF-INBAND-MGMT

ip prefix-list PL-L2LEAF-INBAND-MGMT
   seq 10 permit 192.168.10.0/24

interface Vlan4092
   description Inband Management
   no shutdown
   mtu 1500
   ip address 192.168.10.2/24
   ip attached-host route export 19
   ip virtual-router address 192.168.10.1

router bgp 65000.0
   router-id 192.168.100.1
   maximum-paths 128 ecmp 128
   no bgp default ipv4-unicast
   bgp asn notation asdot
   distance bgp 20 200 200
   timers bgp 5 15
   graceful-restart restart-time 300
   graceful-restart
   neighbor default send-community
   neighbor IPv4-UNDERLAY-PEERS peer group
   neighbor IPv4-UNDERLAY-PEERS password 7 $1c$G8BQN0ezkiJOX2cuAYpsEA==
   neighbor IPv4-UNDERLAY-PEERS send-community
   neighbor IPv4-UNDERLAY-PEERS maximum-routes 12000
   neighbor MLAG-IPv4-UNDERLAY-PEER peer group
   neighbor MLAG-IPv4-UNDERLAY-PEER remote-as 65000.0
   neighbor MLAG-IPv4-UNDERLAY-PEER next-hop-self
   neighbor MLAG-IPv4-UNDERLAY-PEER description DC1-SP2
   neighbor MLAG-IPv4-UNDERLAY-PEER send-community
   neighbor MLAG-IPv4-UNDERLAY-PEER maximum-routes 12000
   neighbor MLAG-IPv4-UNDERLAY-PEER route-map RM-MLAG-PEER-IN in
   neighbor 172.16.1.1 peer group MLAG-IPv4-UNDERLAY-PEER
   neighbor 172.16.1.1 description DC1-SP2
   redistribute attached-host
   redistribute connected

However the route-map RM-CONN-2-BGP is not applied anywhere. My understanding is that it could be applied in the "redistribute attached-host" (or remove the definition and leave it unfiltered):

(config-router-bgp)#redistribute attached-host route-map ?
  WORD  Route map name

Which component(s) of AVD impacted

eos_designs

How do you run AVD ?

Ansible CLI (with virtual-env or native python)

Steps to reproduce

Fabric file contains:

# Set Design Type to l2ls
design:
  type: l2ls

default_mgmt_method: "inband"
mgmt_interface_vrf: "default"

l3spine:
  defaults:
    platform: vEOS
...
    inband_mgmt_interface: Vlan4092

leaf:
  defaults:
...
    inband_mgmt_subnet: 192.168.10.0/24
    inband_mgmt_interface: Vlan4092


### Relevant log output

_No response_

### Contributing Guide

- [X] I agree to follow this project's Code of Conduct
ClausHolbechArista commented 5 months ago

This is most likely caused by some unforseen combination. The RM-CONN-2-BGP route-map is usually used on the redistribute connected under BGP. The route-map is only applied for EVPN VTEPs, explaining why it is not being applied here. We need to capture this condition and not generate the route-map + prefix-list for those cases.