Main menu

Performance Counters

Getting Troubled Of Adding PerfMon Counters Manually, Try this

Performance Counters always makes SQL Server DBA life easy by finding the problematic configuration settings for performance issue. But, it is always time consuming and irritating job to add PerfMon counter(s) on the servers. In this article, we are going to discuss how easily we can add performance counter on the server(s).

  • Download and open the attached excel file


  • TypeSQL Server Instance Name”. If SQL instance is default instance, please type the Computer Name


  • TypeNetwork Card Namewith System Network Card Name.(As a general case scenario your servers may have multiple Network Cards, choose the Production V-LAN Network Card (exclude Backup or Heartbeat or Live Migration cards) and add Network Card that is participating in data exchange across the production environment.

  • Go to tab “Command” in excel file and copy the script from the box

  • Start -> Run -> CMDOpen Command Prompt withRun As Administratoroption.

  • Execute the command copied from excel file.

  • KDSSG-PerfCollectV1User defined data collector set will be created automatically. Start the Data Collector set manually.

  • Important Note:
    • The file by default will be created in C drive. So, you have to make sure that you have enough space in the disk.
    • It will capture PERFMON data every 3 seconds interval
    • Please DON’T use blank space in the beginning and at the end of “SQL Server Instance Name” or “Network Name” fields.

    This listed parameters are pre-defined feel free to add any other counters of your choice, however Categories would be SQL/Server/Network/Disk.

Please do provide your valuable insights & feedback so that excel sheet can be enhanced more!


1 Comment

  1. Nice trick! I have a handful of Logman scripts that I manually copy-&-paste to modify for use. I like your technique—well done!

Leave a Reply

Your email address will not be published. Required fields are marked *