Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 230663

Re: VirtualSwitch and Virutalport group details

$
0
0

Try something like this

 

foreach($clusterinGet-Cluster){
   
foreach($esxinGet-VMHost-Location$cluster){
       
Get-VirtualSwitch-VMHost$esx|
       
Select@{N="Cluster";E={$cluster.Name}},
           
@{N="ESXi";E={$esx.Name}},
           
@{N="vSwitch";E={$_.Name}},
           
@{N="Portgroups";E={[string]::Join(',',Get-VirtualPortGroup-VirtualSwitch$_|%{$_.Name})}}
    }
}

Viewing all articles
Browse latest Browse all 230663

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>