vmware / dscr-for-vmware

The Repository contains Microsoft PowerShell Desired State Configuration (DSC) Resources for managing VC and ESXi settings.
Other
139 stars 41 forks source link

vlan tag not migrated to vds using VMHostVDSwitchMigration DSC Resource #288

Closed mikedonleyuoy closed 3 years ago

mikedonleyuoy commented 3 years ago

Using VMHostVDSwitchMigration DSC Resource to migrate a standard switch portgroup to a vdswitch fails to transfer the tagged vlan if the portgroup doesn't exist on the destination vdswitch.

As an example, a standard switch portgroup created using the following

VMHostVssPortGroup "VMHostVssPortGroup_123" { Server = $vmhost Credential = $Credential VMHostName = $vmhost Name = 'vlan123' VssName = 'vSwitch' Ensure = 'Present' VLanId = 123 }

When migrated, will no longer have the vlan tag associated with it.

If the vdSwitch portgroup already exists and has a vlan specified on it, the migrated portgroup uses that setting, so this is purely and issue for newly created vdSwitch portgroups.

SimeonGerginov commented 3 years ago

VMHostVDSwitchMigration DSC Resource was extended to create distributed port groups with VLAN ID with PR #299 and its now available in the latest version of the VMware.vSphereDSC module.