How to use the new Key Health Indicators for Skype for Business Server and Lync Server 2013

Microsoft released a new version of the KHI tools on 28-April-2015. this version of the KHI Tools is an update to an earlier version that was introduces as part of the Lync Networking Guide.

Download: Key Health Indicators for Lync Server 2013 and Skype for Business Server 2015

In this post I’ll go through the process of configuring the KHI by using the script and how to analyze the results.

Steps Required to use the KHI:

1. Download the new Key Health Indicators for Lync Server 2013 and Skype for Business Server 2015 and extract it content to a separate folder.

2. Copy the Create_KHI_Data_Collector.ps1 file to every Lync Server you would like to monitor and analyze the data for.

It is recommended to run it on the following servers:

  • Lync Front End Server
  • Lync Backend Servers (SQL)
  • Mediation Servers (If are not collocated)
  • EDGE Server

    Please note that if you already used the script from the previous Lync Networking guide, there is no need to run this script again.

3. The script itself contains a list of all Lync related counters and once we run it on the server it created a data collector set in which we need to configure in order to capture the raw data based on those counters and export it to a CSV file which later on can be analyzed by the Excel file Microsoft provided.


4. In order to run the script, we need to open any PowerShell windows with Admin rights and run it based on the server we have.

  • Create_KHI_Data_Collector.ps1 –version Skype4B
  • Create_KHI_Data_Collector.ps1 –version LyncServer2013

Another nice option Microsoft added to the script is the ability to run it against remote computer as well:

  • Create_KHI_Data_Collector.ps1 –version Skype4B –computer
  • Create_KHI_Data_Collector.ps1 –version LyncServe2013 –computer


5. Once the script is completed, in the Performance Monitor (perfmon.msc) we can see the new Data collector that was created under User Defined container named KHI:


6. Now that we have the data collector set with all the right counters created, we need to set an automatic schedule for it in order to have a daily log file of all the counter.
In order to set the setting, right-click on the KHI on left side pane and choose properties:


7. On the properties window, we have 5 different tabs we can configure:


  • General – General Information on the data collector such as Keywords, Description and the user it runs with
  • Directory – Here we need to set the directory where we want to keep all the daily log files. if this is a small environment you can keep the files on a local folder (C:KHI) or you can choose write it to a Shared folder where all the servers will report to.
  • Security – The user and groups and the permissions assigned for the specific Data Collector set
  • ScheduleHere we can create one or multiple schedules to set when we want the Data Collector set to start collecting the counters data.
    What I typically configure is a work-day set in order to have relevant data when the system is loaded with users and operations.
  • Stop ConditionThis is important as we don’t have another option on the Schedule tab to actually stop the scheduler if we want co collect data only during working hours. Here you can set the amount of hours you want to collect the logs for.
  • Task – Here we can set additional parameters or arguments we want to add to the data collector.


8. Once the schedule is configured, you’ll notice that the Data Collector set will start generating a daily logs files based on the schedule we’ve set.
Please note that for the analyzing part, we need to have all logs from all the different servers within the same working folder, therefore it’s recommended to copy all relevant KHI files to a single folder.


9. Once we have the logs collected, we are ready to analyze them with the Key_Health_Indicators_-_Analysis_and_Definitions_Workbook.xlsm file.
Once opened, make sure you’ve eanbled both Editing and Content otherwise you won’t be able to analyze the logs.


10. Click on the Start button, and select the folder where you have the CSV file gathered and choose select.
If all files are set correctly the tool will notify us on the amount of files found in the folder and their total size.
In order to start with analyzing the files, choose OK


12. Once you clicked on the OK button, you’ll notice in the bottom bar of the Excel file that it notifying upon its progress:


13. Once completed, a few additional tabs will appear in the Excel file:


  • Charts – Two charts are generated and should be your analysis starting point. The first chart (left-side) is a summary count of how many servers have KHIs beyond threshold per Ring.
    The second chart (right-side) is a view of all the KHIs for each ring across all servers.
  • Timeline – A new metric called “Burst Count” which analyzing the maximum values of the counters to decide if that happened only on a single instance or there were a number of instance causing the maximum burst.
  • Pivots – The provided pivot table can pivot off Rings, Health, Server Role and Server Names. This is a very similar table to what was used in the previous version, with a better view and a few filters which helps determine the key areas which need further troubleshooting.
  • Tables – The actual raw data that was analyzed for manual changes or for further troubleshooting or creation of additional pivots.

An Example of the Counters Pivot Table:


That’s it, I highly recommend to read the KHI_Guide.docx document which is provided as part of the KHI download, it contains a great list of explanations and definitions per each counter which helps determine what the counters are used for and what a bad sub-optimal value actually means.

1 Comment

  1. johnacook

    Reblogged this on JC's Blog-O-Gibberish.

Comments are closed.