Find out if host has a portgroup with vlan X


Situation : Your portgroup names doesn’t make any sense, and it’s not easy to tell tell vlan id from the name. If you want quickly to discover if you have some portgroup on vswitch that handles vlan X this could be handy:

Get-VMHost your_host| Get-VirtualPortGroup | ? {$_.Vlanid -eq 777} | select name,vlanid

This will check if we have any portgroup defined for ‘your_host’ vswitch.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s