Partager via


Monitoring Hyper-V on Server Core using logman

If you are trying to monitor Hyper-V performance and your servers are Server Core you have many options to capture data. The most easiest way is to use perfmon remotely and define a counter set with Hyper-V related counters.Unfortunately sometimes it does not work for several reasons so you can use this procedure to achieve your goal.

The first thing we need to capture Hyper-V counters is to have the list of the counters. At this point we have a very useful command called typeperf. This command will help us te generate the list of our desired counters. In this case we are looking for Hyper-V counters so we just need to run this :

typeperf /q | find "Hyper-V" > countershyperv.txt

If you also need some other counters you can change the filter word and add them to the .txt file.

Once the countershyperv.txt file has been created you just need to import it using logman.

logman.exe create counter HyperVCounters -f bin -cf countershyperv.txt -max 200 -si 30

With this command you will create a counter set with blg format, 200 MB of maximum data and with a sample interval of 30 seconds.

You can find other examples on https://technet.microsoft.com/en-us/library/bb490956.aspx if you need other settings.

For starting and stopping the counter set data collection you just need to run these commands

logman start HyperVCounters

logman stop HyperVCounters

Once the capture is finished you can open the .blg file with perfmon or PAL to analyze the data.

counters.txt

Comments