Cluster Metrics data equivalence (Cluster CPU Usage and Cluster MEM Usage)

This post was originally published on this site

Hi Everyone,

 

I am looking for an equivalence to the following metrics :

 

$ViewCluster = Get-View -ViewType ClusterComputeResource -Filter  @{Name = $ClusterName }

$ViewHosts = $ViewCluster.host.ForEach({ Get-View -Id $_ })

$ViewVMs = $ViewHosts.vm.ForEach({ Get-View -Id $_ })

$viewclusterpool = Get-View -Id $ViewCluster.ResourcePool

 

Does the CPU usage be  approximately the same ?

$ViewCluster.Summary.UsageSummary.CpuEntitledMhz

is similar to:

$($ViewHosts.Summary.QuickStats.OverallCpuUsage | Measure-Object -Sum).sum

is similar to:

$($ViewVMs.Summary.QuickStats.OverallCpuUsage | Measure-Object -Sum).Sum

 

Sums of VMs metrics make sense in the resource pool object  but I am looking for Cluster CPU usage

 

We find similar values for MEM  :

$viewclusterpool.summary.QuickStats.HostMemoryUsage

is similar to

$($ViewVMs.Summary.QuickStats.HostMemoryUsage | Measure-Object -Sum).Sum

and it look like the Cluster Mem usage also, but we cannot find the value from a cluster object.

 

Thanks

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.