Main navigation

How to use Resource Metering in HYPERV

IT Professionals need tools to track usage from specific business units. If you search you can find lot of monitoring tolls that can do this job but most of them need to pay and for free open source need an advance knowledge to install, configure and enable measure metrics for the resources that you want.

I don't want to say don't use Monitoring Tool in your enviroment. But it takes times and need people to do this. If you are alone you need a quick solution until decide your Monitoring Solution in your enviroment.

So today in this article i will show you another feature that was introduced in Windows Server 2012 Hyper-V that isn’t immediately obvious and is driven by using Windows PowerShell. I will explain only basic commands that can use it every day to measure metrics of your VM'S. The feature is amazing and it's sure that i will come back with more advance commands of Resource Metering.

Resource Metering expose the metrics for the following resources used by a virtual machine during a specific period of time:

Average CPU usage, measured in megahertz over a period of time.

Average physical memory usage, measured in megabytes.

Minimum memory usage (lowest amount of physical memory).

Maximum memory usage (highest amount of physical memory).

Maximum amount of disk space allocated to a virtual machine.

Total incoming network traffic, measured in megabytes, for a virtual network adapter.

Total outgoing network traffic, measured in megabytes, for a virtual network adapter.

Let's start to explain with practise.

As usuall open a Powershell as Administrator always.

First we must enable Resource Metering in VM. So TypeEnable-VMResourceMetering –VMName WIN2012X64

​

If you want to verify that Resource Metering is enable in the VM TYPEGet-VM –VMName WIN2012X64| Format-Table Name, ResourceMeteringEnabled

​

Let's see the resource metrics that we get from the VMMeasure-VM –VMName WIN2012X64

​

Let's see more details for the VM.Measure-VM –VMName WIN2012X64 | Format-List

​

If you want to measure network traffic (Measure-VM –VMName WIN2012X64).NetworkMeteredTrafficReport

​

This is my last article for the 2015. I will come back with new Articles and Tutorials in 2016.

Askme4Tech is my Blog to the IT Community. From this site i share tips, news and in depth tutorials for IT Professionals working with Microsoft products.

My goal is to create a share Knowledge base for IT Professionals and Power Users that works with Microsoft Products and to provide valuable help in daily technical problems and keep up to date with news from IT industry.