Hyper-V Performance Counters
Learn the key performance counters to look at to troubleshoot Hyper-V performance.
July 31, 2013
Q: I'm having performance problems on my Hyper-V server. What are some good performance counters to look at?
A: Typically, if poor performance is caused by a local resource on a Hyper-V server (i.e., an application isn't waiting on some remote system), then the problem will be processor, memory, network, or disk related. There are some key performance counters that can help. Below is a picture of a Performance Counter view I have that is great to use to quickly see the health of my Hyper-V server.
For the Processor resource, we can examine the total busy time of each logical processor in the host (used by the host or virtual machines--VMs) (Hyper-V Hypervisor Logical Processor - % Total Run Time), the amount used just by the Hyper-V host (Hyper-V Hypervisor Root Virtual Processor - % Total Run Time), and the amount used by each virtual processor for each VM (Hyper-V Hypervisor Virtual Processor - % Total Run Time).
If you see overall the Logical Processors are consistently over 90 percent busy, then this would show that overall the host is too overloaded. You can look at what is using the processor by looking at the Root Virtual Processor (if it's the Hyper-V host using it) and Virtual Processor for each VM (if it's specific VMs). The Virtual Processor counter for each virtual processor for each VM will also show if its simply a specific VM that is overloaded, which means it might need additional virtual processors added.
For the Memory resource there are two pieces. First, check whether the VM has been allocated enough memory, which can easily be seen by Hyper-V Manager. It shows the Memory Status (also visible through Hyper-V Dynamic Memory VM - Current Pressure), and if the memory is too low, additional memory can be added through such means as Dynamic Memory. This assumes the host has enough memory to even allocate.
Looking at Memory - Available MBytes shows the available memory on the host. However, to check the amount of memory that can be allocated to VMs, look at Hyper-V Dynamic Memory Balancer - Available Memory, which shows memory available over the complete system or for each NUMA node (if NUMA spanning is disabled). Potentially more memory might be needed in the host.
Network overall bytes for each network adapter can be seen by looking at Network Adapter - Bytes Total/sec, and to see how much each virtual network adapter for each VM is using, look at Hyper-V Virtual Network Adapter - Bytes/sec.
Finally, for Storage, typically one cares about the latency of reads and writes, which can be seen for each physical disk (or if SMB/iSCSI, the appropriate counter) by PhysicalDisk - Avg. Disk sec/Read and Avg. Disk sec/Write. The figure should generally be less than 50ms. The queue length can also be useful via Physical Disk - Avg. Disk Read Queue Length and Avg. Disk Write Queue Length.
By looking at all these performance counters together, it should be possible to ascertain the cause of any degraded performance on your system. I actually create a custom MMC console, add all Performance MMC snap-ins, then add my counters and save the customized console so all my counters are easily available.
About the Author
You May Also Like