We run a daily script checking the configuration and status of ESXi hosts on multiple vCenters (>100) using the following:
Foreach ($vC in $vCList){
$ESXiHosts = Get-View -viewtype hostsystem -property Name,OverallStatus,Summary,AlarmActionsEnabled,Config,TriggeredAlarm,VM,ConfigIssue | Sort-Object Name
}
Does anyone know how to modify the above Get-View command so that it filters out the ESXi hosts in clusters matching the *Build cluster wildcard?