Convert a performance counter data collector template into a PAL threshold file
If you want to have all of the counters in a counter log be represented in a PAL report, then use the AllCounterStats feature in the PAL Wizard. This will use all of the thresholds in the PAL threshold files as well as ensure that all of the counters are in the report at Stats Only.
With that said, if you deal with many unique counter and don’t want to create your own threshold file yet, then consider using the script discussed in this blog entry as a starting point.
Due to popular demand, I created a Powershell script that will convert a performance counter data collector template into a PAL threshold file. The script is called a non-imaginative PerfmonTemplateToPalThresholdFile.ps1. Be forewarned that the threshold file produced from this will not have any thresholds in it.
For now, I consider it to be beta, so it can be downloaded from:
https://aka.ms/clinth, then go to PAL/BetaTesting
or
In a few weeks or so, I will include it with the PAL tool – likely v2.4.1.
How to use it
- Ensure Powershell is set to unrestricted – WARNING this can be a potential security risk
- At an administrator Powershell session run: Set-ExecutionPolicy unrestricted
- Place a performance counter data collector template file (it must be in XML format) in the same directory as the script.
- Unblock the script file. Files downloaded from the internet are considered high risk, so go to the properties of the script file and click the Unblock button. Otherwise, the script will not be permitted to run.
- Run the script
- Start a Powershell session and change directory to the script location.
- .\PerfmonTemplateToPalThresholdFile –PerfMonTemplate .\SysTemplate.xml
- A PAL threshold file will be created in the same directory. It will use the DataCollector Name attribute in the template file as the file name.
- Copy the PAL threshold file to the PAL installation directory
- Once the PAL threshold file is created, copy it to the PAL installation directory.
- Run the PAL Wizard and you should see the file in the list of threshold files.
Considerations
- This script is designed for PAL v2.0 and later.
- The PAL threshold file produced will only create statistics only – no thresholds.
- If you goal is to have all of the counters in a counter log to be represented in the PAL report, then use the AllCounterStats feature.
Comments
Anonymous
January 01, 2003
@Jeff - I am assuming you are wanting to export the PAL Threshold file to a Perfmon Template. If that is so, then the option to 'export to perfmon template file' is available in PAL. (3rd step in the Wizard (Threshold File)).Anonymous
December 04, 2013
Clint, can you also provide a converter for the pal threshold file to perfmon template, or does PAL have a directory with all the HTM/XML formats already and I missed it?Anonymous
December 08, 2013
Clint I just wanted to say PAL 2.4 you knocked it out of the park great job on the questions section and allowing us to choose the OS this tool is something I recommend to all of my customers again thank you for giving us an awesome easy tool to use.