Networking 2 (TestTrack Unplugged Series)

This post was last updated on May 11th, 2017 at 08:40 pm

I’ll assume you read the first post in the series.

Networking 2

Things to note:

  • “network administrator is in the process of setting the physical network” = This will likely not work if tested between hosts. In actuality it will usually work because Workstation ignores and just passes VLAN tags along.
  • “cannot send or receive traffic regardless of changes to the OS or virtual machine properties” = However you achieve this it won’t be in the OS or VM. Pretty much narrows it down to on the virtual switch. Only way to block sent/receive for a VM connected to a VDS from the VDS is to block the port.

Also note it doesn’t list which hosts to add to it. This was an oversight during writing, but as written you’d only be expected to add the host the Batch VM is on.

Step 1: Create the VDS

Very straightforward, make the VDS and portgroup and add the two hosts (see note above).

Step 2: Migrate Batch to TestDev

No notes on IP changes so no worries there, just move the VM.

Step 3: Block the port

The text doesn’t include limits like “make sure this doesn’t affect other VMs” so you could block at the port group level:


Or you can take the more precise route and just block the port for Batch



Is there a VDS on the host Batch is on with the right vmnic in use?
$esxcli = Get-EsxCli -VMhost esxi02.dca.vclass.local
$switchlist = $
$switch = $switchlist | where {$_.uplinks -match "vmnic3"}
if ($switch){$one = 1}

Is the portgroup set to the right VLAN?
$pg = $null
$numvms = $null
$vlan = $null
$pg = (get-vm batch).networkadapters[0].networkname
$vlan = (get-vdportgroup -name $pg).vlanconfiguration.vlanid
if ($vlan -eq 101) {$two = 1}

Is the port blocked?
$found = get-vdport -VDPortgroup (get-vm batch | get-networkadapter).NetworkName -key ((get-vm batch | get-networkadapter).extensiondata.backing.port.portkey)

if ($found.isblocked) {$three = 1}

This entry was posted in Certification, Computing, Network, PowerShell, Scripting, Virtualization, VMware and tagged , , , , , . Bookmark the permalink.

Leave a Reply