page contents

Setting up Windows Performance Monitor Templates


To log valuable information about your database server such as disk, processor, memory and network, it is important to configure and schedule the performance counter logging. In the following steps, you will configure the database server for performance counter logging. This information will be logged to performance counter log files.

First we can setup the template for the SQL Server:

  1. If you are using a Named instance of SQL Server, other than default MSSQLSERVER, follow these steps, otherwise go to step 6:
  2. Browse to the Server2008_SQL_Named_Instance.xml file under [DynamicsPerf 2.00\DynamicsPerf\Windows Perfmon Scripts]
  3. Open the file in Notepad
  4. Replace [InstanceName] with the actual name of your named SQL instance: <Counter>\MSSQL$InstanceName:Access Methods\Forwarded Records/sec</Counter>
  5. Save the file
  6. Start > Run > Perfmon
  7. Expand Data Collector Set
  8. Right click User Defined and select New > Data Collector Set
  9. Performance Monitoring For Dynamics AX
  10. Name it “SQL Server Performance”
  11. Select the “Create from a template” option.
  12. Click Next
  13. Select “System Performance” and click Browse to browse to the Server2008_SQL_Default_Instance .xml file if you are using a Default SQL Server or the Server2008_SQL_Named_Instance.xml file if you are using a Named SQL Server
  14. Performance Monitoring for Dynamics Ax
  15. Click Finish
  16. Right-click on the SQL Server Performance data collector set and click Properties
  17. By default, the performance counter logs will log to C:\perflogs. If you wish to change this path, follow these steps. Otherwise, go to step 18:
  18. Select the Directory tab
  19. Browse to a local root directory to where you want to store the performance counter logs.
  20. Select the Schedule tab
  21. Select beginning date as of today and leave the rest as default so it will run continuously without an end date.
  22. Performance Monitoring for Dynamics Ax
  23. Click OK to close Folder action window
  24. Ensure All schedules enabled checkbox is checked
  25. Click OK to close window
  26. You can also set up a condition to stop the logging with specific condition on file size and duration. For example, you can click Stop Condition and choose the restart the logging if the file size reaches 500,000 MB.
  27. Performance Monitoring for Dynamics Ax
  28. If you right-click the Template [SQL Server Performance] and select Data Manager, you can also change the default settings.

 Note: to verify that SQL counters are correctly, please check specific counters such as [SQL Server: Buffer Manager\Page Life Expectancy] or [SQL Server: SQL Statistics\ Batch Requests/sec]

 

Now let’s define the template for the Dynamics AX AOS Server:

  1. Start > Run > Perfmon
  2. Expand Data Collector Sets
  3. Right click User Defined and select New > Data Collector Set.
  4. Name it “AOS Server Performance”
  5. Select the “Create from a template” option.
  6. Click Next
  7. Select “System Performance” and click Browse to browse to the Server2008_AOS.xml file under [DynamicsPerf 2.00\DynamicsPerf\Windows Perfmon Scripts]
  8. Click Finish
  9. Right-click on the AOS Server Performance data collector set and click Properties
  10. NOTE: By default, the performance counter logs will log to C:\perflogs. If you wish to change this path, follow these steps. Otherwise, go to step 13
  11. Select the Directory tab
  12. Browse to a local root directory to where you want to store the performance counter logs.
  13. Select the Schedule tab
  14. Click the Add button to create new schedule
  15. Select beginning date as of today and leave the rest as default so it will run continuously without an end date.
  16. Click OK to close Folder action window
  17. Ensure All schedules enabled checkbox is checked
  18. Click OK to close window
You can now manually start the two templates by clicking the Green arrow for each Template:
Performance Monitoring for Dynamics Ax
You should then see the new icon for each template that shows the data is been collected:
AOSPerfmon
Regards,
@BertrandCaillet
Principal Premier Field Engineer
Comments (7)
  1. hi. I’m new the Dynamics Perf – could you tell me if the Perfmon Counters feed into the DynamicsPerf database and these stats reported by the various script available in the ‘Performance Analyzer 2.00 Analyze Data’ solution? Or are these to be analysed separately?

    I’m assuming the latter but in a previous comment you’ve stated “I recommend you to set up the template on all servers in Production, not only the AOS Servers. Then you can run the tool during one week to understand the resource consumption per server role.” which made me think otherwise. Is there a tool for analysing the perfmon stats?

    thanks

    1. I’ve just spotted that DynamicsPerf has a link to PAL – is this what you recommend? thanks

      1. Hello Ukal,

        There are few options here: first of all, you have the Windows Performance Monitoring tool. You can get the Templates for each server role (AOS, SQL…) from DynamicsPerf Solution or from PAL tool as well.

        Then you also have new features in DynamicsPerf 2.0 where memory DMVs for example can be retrieved with the SP and can be analyzed directly from DynamicsPerf Database.

        Regards,
        @BertrandCaillet

  2. Axbert says:

    Should the setup be made for each AOS, or is it sufficient to do it on one AOS only?

    1. I recommend you to set up the template on all servers in Production, not only the AOS Servers. Then you can run the tool during one week to understand the ressource consumption per server role.

      Regards,
      Bertrand

  3. Daps Bellos says:

    Fantastic article .Thanks Bertrand.

Comments are closed.

Skip to main content