in our environment we have multiple vcentres, and in each vcentre we have multiple clusters .
I have portgroup name, and cluster name ,
from the above i need to get a vswitch name , and a connected host to the vswitch,
any suggestion would be great
Are these VSS or VDS switches?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Since a VDS can have more than 1 ESX node connected, you can't provide "a connected host to the vswitch" as you seem to require.