Closed jonnic closed 3 years ago
@jonnic - Thank you for raising this issue, and you interested in ansible-avd!
This is the intended behavior, as in Arista EOS when an interface belongs to a port-channel, the switchport configuration is only required on the parent Port-Channel interface. This is why in the automated document eos_cli_config_gen
provides this additional information in the tables.
Example:
interface Port-Channel10
description HostC_bond0
switchport access vlan 30
mlag 10
spanning-tree portfast
!
interface Port-Channel11
description HostE_bond0
switchport access vlan 20
mlag 11
spanning-tree portfast
!
interface Ethernet10
description HostC_eth0
channel-group 10 mode active
!
interface Ethernet11
description HostE_eth0
channel-group 11 mode active
reference:
If you have additional questions, please feel free to reach out to ansible@arista.com
Thanks for looking at this. There are a couple of scenarios where we require the underlying interface to have a switchport configuration as well as the port-channel.
We've encountered a bug in EOS (BUG412920) that where when committing a configuration from a config session the order in which trunk groups gets applied is "racey" which can result in the wrong trunk group being applied on an interface. The work-around is to configure the underlying ethernet port with the same switchport configuration as the portchannel. This may have been addressed in the latest eos code.
We want to be able to use lacp failback to allow hosts to be provisioned on the interface, in production the interface will be a trunk on a bonded port. However for the initial PXE boot to work LACP failback individual will mean that the configuration from the individual ethernet ports will be used, these will be configured to be on an access port for the provisioning service.
@jonnic, thanks for this clarification, re-opened issue, and tracking this as an enhancement to support this use case.
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 15 days
@jonnic lcap failback has been added with PR #852, with recommended approach in eos_designs
.
Issue Type
Summary
If an ethernet interface is configured to be part of a port-channel then the switchport configuration is not run.
Role or Module Name
eos_cli_config_gen/templates/eos/ethernet-interfaces.j2
arista.avd
collection and Python libraries versionThis is working on the development branch of avd commit 15f74e30371c89cd563a5c6fb533818fa47ded89
YAML input:-
The
switchport mode trunk
which we'd expect to see in the output is not present.I believe that the fix is to move the switchport configuration to before the channel group definition in the template:-
This produces the desired results in my testing.