07 February 2019

Microsoft Hyper-V monitoring by Zabbix

Good afternoon!

We continue to publish materials on monitoring. Today we are analyzing Hyper-V from Microsoft and as usual our templates for monitoring via Zabbix are available and are at the end of this article.

The simplest task is to monitor the stand-alone Hyper-V with virtual machines, monitoring the Hyper-V failover cluster, the task is more complicated, somehow we’ll lay out its solution. Today we show how we monitor Hyper-V hosts from our customers.

Our goal is to collect useful information about Hyper-V and virtual machines to evaluate server performance, monitor the state of virtual machines and the host itself.

To begin with, we suggest that you study a couple of articles from Microsoft engineers using the standard Performance Monitor tool to monitor Hyper-V and what to look for when you look for performance problems without this knowledge, Zabbix does not help much, you need to understand what you are analyzing.

In addition to the processor and memory

These articles were taken as a basis for setting up triggers in the template.

We are not trying to remove all possible metrics from Hyper-V, it’s not necessary,  just the key ones are enough:

  • Performance Logical CPU, Virtual CPU, Root CPU
  • Memory Usage
  • Performance of virtual network adapters and switches
  • Collecting statistics on virtual machines and monitoring their health
  • Monitoring the Hyper-V Virtual Machine Management service

Discover

The template automatically finds the following objects and adds performance counters to them

  • Virtual Network Host Adapters
  • Virtual network switches (virtual switch)
  • Virtual machines
  • Virtual network adapters (synthetic network adapter)
  • Virtual Disks (VHDX)

Triggers

As we usually do, we put all the parameters of the triggers in macros (User macros) so that they can easily be redefined for specific tasks. In the template there are enough standard triggers for monitoring CPU, memory, network, from interesting triggers:

VMs changed state to Paused – switch virtual machines to Pause mode. It happens that somewhere they did not keep track of the disk space, or the disc was lost or some other malfunction, and the machines begin to gradually switch to the Pause mode. If the value is incremented within 30 minutes, the trigger will fire.

VM Average Memory Pressure – when the dynamic memory is installed, the virtual machine can request additional memory, this trigger is triggered when the machine needs memory, but its Hyper-V does not allocate.

Charts

The template has predefined graphics that can help you quickly see what happens to the Hyper-V host

Utilization Logical CPU

Utilization memory

Network adapter performance


Utilization VMs network adapters


Performance VHD VMs

Also, do not forget to set our awesome Template OS Windows Active to monitor the host OS, these templates work fine in pairs.

Where can I download

Template Microsoft Hyper-V Template and scripts you can download for free from our repository in GitHub, as well as in Zabbix Share.

We will be happy to answer your questions and suggestions.