Welcome to MSDN Blogs Sign in | Join | Help

News

  • All posts on this blog are meant for illustration purposes only and not intended for use in production. The following disclaimer applied to all code used in this blog: Copyright (c) Microsoft Corporation. All rights reserved. THIS CODE IS MADE AVAILABLE AS IS, WITHOUT WARRANTY OF ANY KIND. THE ENTIRE RISK OF THE USE OR THE RESULTS FROM THE USE OF THIS CODE REMAINS WITH THE USER. USE AND REDISTRIBUTION OF THIS CODE, WITH OR WITHOUT MODIFICATION, IS HEREBY PERMITTED.
TraceParser Video Training Part II: Configuration, Collection and Importing
 

TraceParser - Collecting and Importing

This video will give you a step by step introduction to configuring Dynamics AX for tracing, collecting traces from both the TracingCockpit and Client Configuration Utility and importing these traces to the TraceParser database.

If you do not have TraceParser installed, make sure to review the first video on installing TraceParser at http://blogs.msdn.com/axperf/archive/2008/07/18/traceparser-video-training-part-i-installation.aspx


Video: Trace Parser Collection and Importing

Registry Keys

Registry Keys for Dynamics AX Client can be found under HKCU\Software\Microsoft\Dynamics\5.0\Configuration

Registry Keys for Dynamics AX Server can be found under

HKLM\System\CurrentControlSet\Services\Dynamics Server\5.0\01\Configuration

If there is more than one instance of Dynamics Server running, you will want to find the appropriate instance.

Under each of these, will want to find a key named Current and note the value of this key.  This is your active configuration for the Client.  You should find a corresponding subkey under Configuration which houses the registry keys for your current installation.  TraceParser specific keys are labeled with the trace prefix.  An explanation of each key and its meaning is below:

traceallowclient

Ignored for client, on server set to 0x1 to allow the client to turn on tracing

tracebuffersize

Size in MB of buffer space allocated for ETW

traceeventsenabled

A semicolon delimited list of event flags. These correspond to the trace events in the AX Client Configuration Utility

tracemaxbuffers

Maximum number of buffers to use for ETW. If you are getting any dropped event errors, you will want to increase this.

tracemaxfilesize

Maximum disk space usage in MB for the ETW tracefile. You will need to have enough free space to allocate a file of this size.

traceminbuffers

Minimum amount of buffers to allocate for ETW. If you are getting any dropped event errors, you will want to increase this.

tracestart

0x0 if tracing is currently stopped, or set to 0x1 when tracing is started

tracexppmethodcalldepth

Depth of the call stack to collect when tracing

 

Trace Events

Which events you specify will affect what information is collected when tracing. By default, if you install TraceParser using the client integration, it will automatically turn on most events necessary for tracing. If you would like to define your own events, here is an explanation.

RPC round trips to server

Remote Procedure Calls between Client and Server

X++ method calls

Method calls within the X++ language

Function Calls

X++ built in functions such as int2str

Number of nested calls

Depth of the X++ call stack when collecting traces

SQL Statements

Queries issues to the SQL Database

Bind variables

Parameters specified for each of the SQL queries

Row fetch

Number of rows returned by SQL

Row fetch summary

Same as row fetch, and includes timing information

Connect and disconnect

Connections and disconnections to SQL

Transactions: TTSBegin, TTSCommit, TTSAbort

Transaction statistics, not necessary if X++ method tracing is enabled

Using LOGMAN To Query Trace Providers

Open a command prompt and type "logman -ets query providers". This will show you a list of running providers. When AX Tracing is turned on, you should see an output similar to below:

C:\>logman -ets query providers

Session                    Id     File
-------------------------------------------------------------------------------
MSDTC_TRACE_SESSION        2      C:\WINDOWS\system32\MSDtc\trace\dtctrace.log
AX_TRACE_client_{CE6D980E-3F17-490A-951F-ECE4BE57A597} 3      c:\log\AOS_AXPTRACEDC_2712_20080731194343_client.trc
AX_TRACE_AOS_{CD8AE17D-33CA-4C75-8DC9-79DCA90387E7} 4      c:\log\AOS_AXPTRACEDC_2712_20080731194343.trc

The command completed successfully. 

Coming Soon - Part III

I will show you how to analyze the traces that we just collected.  This might be a 2 part series that starts with the basics and then covers the more advanced topics.

Future series:

  • Automation (using X++, C# and Batch Files)
  • Case Studies using TraceParser to identify issues
Posted: Wednesday, July 30, 2008 5:37 PM by rayben

Comments

No Comments

Anonymous comments are disabled
Page view tracker