DRS script fails if DRS is not enabled? DRS script fails ExtensionData is not populated...
--------------------------
$cluster.ExtensionData.ConfigurationEx.Group | %{
if($_ -is [VMware.Vim.ClusterVmGroup]){
$vmGroup.Add($_.Name,$_)
}
else{
$hostGroup.Add($_.Name,$_)
}
}
------------------------------------------------
f we have extensive variance in our environments,Script needs to do explicit checking.
Is $_.Name is null, then error, if $_ is null, error.
However, DRS may not be enabled, or configured, the script will need to handle this potential.
Please guide me on how to handle the script, if DRS is not enabled.
Thank you,
Basavaraj
LucDDRS Reporting