vmware_dvswitch_lacp – Manage LACP configuration on a Distributed Switch¶
New in version 2.8.
Synopsis¶
This module can be used to configure Link Aggregation Control Protocol (LACP) support mode and Link Aggregation Groups (LAGs).
Requirements¶
The below requirements are needed on the host that executes this module.
python >= 2.6
PyVmomi
Parameters¶
Notes¶
Note
Tested on vSphere 6.7
You need to run the task two times if you want to remove all LAGs and change the support mode to ‘basic’
Examples¶
- name: Enable enhanced mode on a Distributed Switch
vmware_dvswitch_lacp:
hostname: '{{ inventory_hostname }}'
username: '{{ vcenter_username }}'
password: '{{ vcenter_password }}'
switch: dvSwitch
support_mode: enhanced
validate_certs: "{{ validate_vcenter_certs }}"
delegate_to: localhost
loop_control:
label: "{{ item.name }}"
with_items: "{{ vcenter_distributed_switches }}"
- name: Enable enhanced mode and create two LAGs on a Distributed Switch
vmware_dvswitch_lacp:
hostname: '{{ inventory_hostname }}'
username: '{{ vcenter_username }}'
password: '{{ vcenter_password }}'
switch: dvSwitch
support_mode: enhanced
link_aggregation_groups:
- name: lag1
uplink_number: 2
mode: active
load_balancing_mode: srcDestIpTcpUdpPortVlan
- name: lag2
uplink_number: 2
mode: passive
load_balancing_mode: srcDestIp
validate_certs: "{{ validate_vcenter_certs }}"
delegate_to: localhost
loop_control:
label: "{{ item.name }}"
with_items: "{{ vcenter_distributed_switches }}"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Status¶
This module is not guaranteed to have a backwards compatible interface. [preview]
This module is maintained by the Ansible Community. [community]
Authors¶
Christian Kotte (@ckotte)
Hint
If you notice any issues in this documentation, you can edit this document to improve it.