Freigeben über


Hyper-V Performance Counters - Part five of many - "Hyper-VM VM Vid Numa Node"

There are a couple of performance counter sets in Hyper-V that show memory usage. These counters tend to show memory used by one component of the system and the "Hyper-V VM Vid Numa Node" counter set is no different.

This counter set is intended to show memory used by the Virtual Infrastructure Driver (Vid). The good news is this counter set shows "guest physical memory". This memory includes the allocation you specify when creating the VM and some other support memory like video memory. It is the majority of the memory used by the Virtual Machine (VM).

Hyper-V VM Vid Numa Node shows memory on a per node basis. If you have an AMD machine you will likely see a Non-uniform Memory Access (NUMA) node for each processor. If you have an Intel based machine you will see anywhere from one to many nodes depending on the architecture.

The following are the performance counters in the counter set;

  • PageCount       - Number of 4K pages that the node contains. To find the total physical memory on the system you would add PageCount from each NUMA node and multiply by 4Kbytes.
  • PagesInUse      - Number of pages in use by the Vid on this node. Keep in mind this is most but now all memory supporting a VM.
  • ProcessorCount           - Number of logical processors this node contains. Logical process are equal to the number of processor (sockets) * number of cores per processor * 2 if you have HyperThreading (HT) or now called Symmetric Multithreading (SMT)

  Enjoy,

  Anthony F. Voellm (aka Tony)

Comments

  • Anonymous
    September 28, 2008
    PingBack from http://www.easycoded.com/hyper-v-performance-counters-part-five-of-many-hyper-vm-vm-vid-numa-node/

  • Anonymous
    September 28, 2008
    The comment has been removed

  • Anonymous
    October 09, 2008
    Is there a way of determining the memory consumption of the guest partitions but from the root/hypervisor level.   I have looked through the list of available Hyper-V counters and there are a number of counters that discuss the number of pages assigned, but not the number used. Any advice you can give would be great. Rob

  • Anonymous
    December 05, 2008
    Hi, I am interested in guest memory usage, for that when I look for instances in "Win32_PerfFormattedData_VidPerfProvider_HyperVVMVidNumaNode" in WMI explorer its NILL. What could be the reason. Do I need to enable something. I have couple of VMs (w2k3 sp2) running on the server. Thanks in advance  --- [Tony's reply] Obtaining guest memory is currently not that easy in WS08.  In Win7 we have fixed and simplified what is presented by the Hyper-V VM Vid counterset and you will see the changes in Win7 Beta. Getting feedback on the new changes would be great. As for WS08 the best thing to do is read the memory from the VM configuration and add roughly 32MB.  This is a good working number for capacity planning.  If you want more on memory fitting please check out the "Server Performance WS08 Tuning Guide" referenced elsewhere in this blog.

  • Anonymous
    April 21, 2009
    Is this "series" still ongoing? Not seen an update in a while now. Also, on the subject of the Monitor Transition Cost counter: are these World Switches? If so, how can we see a count as well? If they're not, is there a way to monitor world switches and see their cost as opposed to context switches? And lastly, what about TLB misses? I've seen the TLB related counters but not sure which one represents these (though I'm guessing none of them does)


Tony's Reply - Windows Server 2008 R2 Beta+ has kept me pretty busy so the series has slowed.  It will pick up again in time.  Monitor Transition Cost is the not the cost of VM exits.  There are other counters that help gauge that cost. As for TLB counters look for "Large TLB Refills" and "Small TLB Refills" in hte Hyper-V [Root] Virtual processor counter sets.

  • Anonymous
    April 22, 2009
    Thanks for the quick answer. Mind giving some counters that actually do gauge World Switch cost and frequency? I've had no luck so far figuring it out. As far as Monitor Transition Cost goes, you mentioned that they're similar to Context Switches but from User/Kernel mode to Hypervisor mode, but I'm not sure if I understand the difference between a WS and the Monitor Transition...  --- Tony's reply - Hannes - acutally the Monitor Transition cost is what you want.  Late night.  The cost if the minimum time to enter & exit a VM.  Each platform as you know as a different cost but this can help you rate how good the virtualization hardware is.  The counter to look at is the Hypercall cost.  This is the average time spent in the hypervisor doing something on behalf of a VM.  Hypercall do things like flush TLB entries.

  • Anonymous
    April 23, 2009
    Ahhh so I did understand it after all ;-) Yea working late can do that to you. So just to clear things out, am I assuming the following correctly?

  • Monitor Transition cost is the cost of the VMRUN or VMEXIT instructions and in that way sort of a benchmark of the hardware.
  • The Hypercalls/sec counter is how often a Hypercall happens, but for each Hypercall you need a VMRUN and VMEXIT instruction, so 2 * (Monitor Transition Cost) * (Hypercalls/sec) is the cost per second for World Switches. (Are Monitor Transitions measured in nanoseconds or clockcycles? I'm assuming the former?) I could be getting this all wrong to be honest, but that's what I made of it so far. Also, are there any "channels" we can use to get some help when it comes to these counters, especially the Hyper-V ones? I don't exactly want to be wasting your time and posting them in your blog each time. Any forums, people, ... you can hook me up with who might have the time and expertise to help out every once in a while? Thanks a lot, you've been a great help  

 Tony's Reply:  The monitor cost is actually the minimum[(vmenter1 + vmexit1), (vmenter2 + vmexit2)], ... , (vmenter16 + vmexit16)].  It is the minimum of the total enter + exit cost over 16 trials.