Hi,
I wrote script to display the CPU and Memory utilization of the hosts in a cluster on a specific vCenter and that's working perfectly.
Can someone please help me to get a script that could calculate if the load is balanced or not?
A quick way of looking at the load distribution in a cluster is by getting the fairness values for each ESXi node in the cluster.
The explanation for these fairness values can be found in the HostListSummaryQuickStats page.
Get-Cluster -PipelineVariable cluster | Get-VMHost |
Select @{N='Cluster';E={$cluster.Name}},
Name,
@{N='CPU Fairness';E={$_.ExtensionData.Summary.QuickStats.DistributedCpuFairness}},
@{N='Memory Fairness';E={$_.ExtensionData.Summary.QuickStats.DistributedMemoryFairness}}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thanks for your reply.. I used your script but that gives only Fairness values for the CPU and Memory..
Could you please guide me through with a script that would calculate and display like:
Current host load standard deviation: 0.xxxxx
On the basis of this, I will be able to define load balanced/imbalanced comparing with the Target.