vim_dvs_portgroup¶
Distributed Port Group (DPG) lifecycle via SOAP.
DPG identity:
key(server-assigned, stable, used by VM NIC backings)name(human-readable; we use it as the lookup key)portgroupKeyreturned insaltext.vcf.clients.vim_vm_nic.list_()is this samekey.
Two creation paths:
create_vlan()for VLAN-backed (standard / trunk / private)create_overlay()for overlay-backed (early-binding ephemeral for use under NSX/Avi)
NIC teaming / physical-uplink failover mode: get_teaming() and
set_teaming() cover the load-balancing / explicit-failover
policies on the DPG’s default port config.
LACP-with-LAG is a follow-up: it requires LAG creation and
ReconfigureLacp_Task on the parent DVS (see
saltext.vcf.clients.vim_dvs) plus per-DPG
VMwareDvsLagVlanConfig binding via UplinkPortOrderPolicy.
- saltext.vcf.clients.vim_dvs_portgroup.create_vlan(opts, dvs_name_or_id, name, *, vlan_id=0, num_ports=8, binding='earlyBinding', auto_expand=True, promiscuous=False, profile=None)[source]¶
Create a VLAN-backed DPG.
vlan_id of 0 means the DPG is untagged. Use
create_trunk()for a trunk port group.
- saltext.vcf.clients.vim_dvs_portgroup.create_trunk(opts, dvs_name_or_id, name, *, vlan_ranges, num_ports=8, binding='earlyBinding', profile=None)[source]¶
Create a VLAN-trunk-backed DPG. vlan_ranges is a list of
(start, end)tuples.
- saltext.vcf.clients.vim_dvs_portgroup.reconfigure(opts, dvs_name_or_id, name, *, vlan_id=None, num_ports=None, promiscuous=None, profile=None)[source]¶
Update DPG config fields. Only non-None fields are applied.
- saltext.vcf.clients.vim_dvs_portgroup.get_teaming(opts, dvs_name_or_id, name, profile=None)[source]¶
Return the current uplink teaming policy for DPG name (or
None).
- saltext.vcf.clients.vim_dvs_portgroup.set_teaming(opts, dvs_name_or_id, name, *, policy, reverse_policy=None, notify_switches=None, rolling_order=None, check_beacon=None, active_uplinks=None, standby_uplinks=None, profile=None)[source]¶
Set the uplink teaming policy on DPG name.
policy is one of
loadbalance_ip,loadbalance_srcmac,loadbalance_srcid,failover_explicit,loadbalance_loadbased.