Capture performance monitor counters using performance monitor
How to run performance counters on Windows Server 2008 R2
Today I needed to setup a configuration to mirror what someone had sent me so that I can estimate a baseline of disk performance to calculate disk IOPs for a SQL server move to a different datacenter. This will only be a simple setup to get at the numbers I need so I can start the compare. If I have more time I will show values and calculations in another post.
1. Open Performance Monitor by running PERFMON in the “Run…” textbox or navigating to Icon under all programs
2. Under “Reliability and Performance”, expand “Data Collector Sets”.
3. Right-click on “User Defined”
4. Select “New” from the popup menu then select “Data Collector Set”.
5. Assign a name for the new log settings. Eg.: “ServerName_Perfmon.”
6. Under the “Create data logs” section, check the checkbox for “Performance counter”.
7. Click the “Add…” button to start adding counters for each “Performance object” you wish to add counters from. Add the desired counters. In my example today I am using PhysicalDisk > Disk Transfers/sec, Disk Reads/sec, Disk Writes/sec and _Totals
8. Once you have added all the required counters, click the “OK” button and then click the “Next” button.
9. Specify the location to save the file.
10. Click the “Finish” button.
I wanted to Run my User Defined data collector set now so I Right-click the new file under the “User Defined” and selected "Start" You could continue onto step 11 if you wanted to Schedule a Start and End time
11. Right-click the new file under the “User Defined” folder and select “Properties”.
12. Click on the “Schedule” tab.
13. Click on the “Add” button to schedule a “Beginning date:” and “Start time:” and then click on the “Stop Condition” tab to specify the “Overall duration.”
To make the PERFMON file as a template to make it reusable, you can save the list of counters as an .xml file so that you can use it on other SQL Server hosts. Right-click on the new log folder under the “User Defined” folder and select “Save Template…” to save the file as .xml in to the designated location.
To use a template perfmon counter log file in a Windows Server 2008 or 2008 R2 host server, open PerfMon > Reliability and Performance > Data Collector Sets > right-click on “User Defined” > New > “Data Collector Set” > name the file > select the “Create from a template (Recommended)” radio button > click the “Browse” button to browse to the template file > select the template .xml file > click the “Next” button > specify the location to save the file > the “Save and close” radio button will be selected > hit the “Finish” button.
To modify the new “DataCollector01” set, right-click on it and select “Properties” to add or remove the counters as necessary. Click the “OK” button when done.
To schedule the new log file, right-click on the new file under the “User Defined” section, click “Properties”, then click the “Schedule” tab.
To convert perfmon .blg files to .csv files, you can use the command prompt and navigate to the directory the binary file is located and type:
relog logfile.blg -f CSV -o newfile.csv
REFERENCES:
How to create a log using System Monitor in Windows
https://support.microsoft.com/en-us/help/248345/how-to-create-a-log-using-system-monitor-in-windows
Using Performance Monitor from https://docs.microsoft.com
Today I needed to setup a configuration to mirror what someone had sent me so that I can estimate a baseline of disk performance to calculate disk IOPs for a SQL server move to a different datacenter. This will only be a simple setup to get at the numbers I need so I can start the compare. If I have more time I will show values and calculations in another post.
1. Open Performance Monitor by running PERFMON in the “Run…” textbox or navigating to Icon under all programs
2. Under “Reliability and Performance”, expand “Data Collector Sets”.
3. Right-click on “User Defined”
4. Select “New” from the popup menu then select “Data Collector Set”.
5. Assign a name for the new log settings. Eg.: “ServerName_Perfmon.”
6. Under the “Create data logs” section, check the checkbox for “Performance counter”.
7. Click the “Add…” button to start adding counters for each “Performance object” you wish to add counters from. Add the desired counters. In my example today I am using PhysicalDisk > Disk Transfers/sec, Disk Reads/sec, Disk Writes/sec and _Totals
8. Once you have added all the required counters, click the “OK” button and then click the “Next” button.
9. Specify the location to save the file.
10. Click the “Finish” button.
I wanted to Run my User Defined data collector set now so I Right-click the new file under the “User Defined” and selected "Start" You could continue onto step 11 if you wanted to Schedule a Start and End time
11. Right-click the new file under the “User Defined” folder and select “Properties”.
12. Click on the “Schedule” tab.
13. Click on the “Add” button to schedule a “Beginning date:” and “Start time:” and then click on the “Stop Condition” tab to specify the “Overall duration.”
To make the PERFMON file as a template to make it reusable, you can save the list of counters as an .xml file so that you can use it on other SQL Server hosts. Right-click on the new log folder under the “User Defined” folder and select “Save Template…” to save the file as .xml in to the designated location.
To use a template perfmon counter log file in a Windows Server 2008 or 2008 R2 host server, open PerfMon > Reliability and Performance > Data Collector Sets > right-click on “User Defined” > New > “Data Collector Set” > name the file > select the “Create from a template (Recommended)” radio button > click the “Browse” button to browse to the template file > select the template .xml file > click the “Next” button > specify the location to save the file > the “Save and close” radio button will be selected > hit the “Finish” button.
To modify the new “DataCollector01” set, right-click on it and select “Properties” to add or remove the counters as necessary. Click the “OK” button when done.
To schedule the new log file, right-click on the new file under the “User Defined” section, click “Properties”, then click the “Schedule” tab.
To convert perfmon .blg files to .csv files, you can use the command prompt and navigate to the directory the binary file is located and type:
relog logfile.blg -f CSV -o newfile.csv
REFERENCES:
How to create a log using System Monitor in Windows
https://support.microsoft.com/en-us/help/248345/how-to-create-a-log-using-system-monitor-in-windows
Using Performance Monitor from https://docs.microsoft.com
Comments
Post a Comment