VMware Cloud Community
thb_
Enthusiast
Enthusiast
Jump to solution

enumerate memory overhead

is there a way to enumerate the memory overhead of a vm without using the GUI?

I would like to get the information over VI Toolkit.

any ideas?

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

Yes, you could, for example, do it like this:

Get-VM <VM-name> | Get-Stat -Stat mem.overhead.average -Start (Get-Date).adddays(-1) -Finish (Get-Date) -MaxSamples 48 -IntervalMins 30


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

0 Kudos
6 Replies
Dave_Mishchenko
Immortal
Immortal
Jump to solution

our discussion has been moved to the VI Toolkit (for Windows) forum

Dave Mishchenko

VMware Communities User Moderator

0 Kudos
LucD
Leadership
Leadership
Jump to solution

Yes, you could, for example, do it like this:

Get-VM <VM-name> | Get-Stat -Stat mem.overhead.average -Start (Get-Date).adddays(-1) -Finish (Get-Date) -MaxSamples 48 -IntervalMins 30


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
thb_
Enthusiast
Enthusiast
Jump to solution

So when i look at the output it's not the same what i see in the GUI.

Why is that?

I also thought the Memory Overhead is fix.

In the ressource management it a table that shows the overhead for VMs with X vCPUs and X Memory and 32Bit or 64 Bit GuestOS.

0 Kudos
LucD
Leadership
Leadership
Jump to solution

Depends what type of statistics you are looking at in the GUI.

If you select "realtime" in the GUI the cmdlet should be

Get-VM <VM-name> | Get-Stat -Stat mem.overhead.average -Start (Get-Date).adddays(-1) -Finish (Get-Date) -MaxSamples 100 -Realtime

Also take into account that the date/time the Get-Stat returns is in UTC while the VI Client shows local time.

Memory overhead for guest is not fixed afaik, it can change during the life of the guest.

I'm not sure to which Resource Mgmt table you are referring, could you give a pointer ?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

thb_
Enthusiast
Enthusiast
Jump to solution

Page 142,

but you're right. I thought it's fixed. But after reading it again i understand it's not

And one more thing. Is there a list of all "MetricId"

with:

get-vm &lt;vmname&gt; | Get-Stat -memory i only get those Ids:

MetricId

-


mem.usage.average

mem.granted.average

mem.active.average

mem.vmmemctl.average

thanks!

0 Kudos
LucD
Leadership
Leadership
Jump to solution

You can find a list of the metrics in the SDK Programming Guide appendix A.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference