Microsoft Dynamics AX provides multiple locations to set tracing options for server and client activity. You can set traces:

  • In the Microsoft Dynamics AX Server Configuration Utility on the computer running the Application Object Server (AOS) instance.

  • In the Microsoft Dynamics AX Configuration Utility on a client or for an instance of Business Connector that is running non-interactively.

  • Within Microsoft Dynamics AX, in the Tools> dialog box, on the and tabs.

    Note Note

    This option is not available unless you also select Allow client tracing on Application Object Server instancein the Server Configuration Utility.


In general, we recommend that you use these tools to help you trace in the following scenarios:

Scenario

Tool

Monitoring general performance

Trace from the Server Configuration Utility on a computer running an AOS instance.

Standard troubleshooting

Trace from the Server Configuration Utility on a computer running an AOS instance.

Debugging code

Trace from the Configuration Utility on the client

- or -

For line-by-line tracing only, use the options in the Tools> Optionsdialog box. This may option may degrade system performance.

Create an application profile

Trace from the Configuration Utility on the client.

Deep troubleshooting

Trace from the Server Configuration Utility on the AOS.

Considerations for tracing from the configuration utilities

When you are setting up tracing from the Configuration Utility or Server Configuration Utility, be aware of the following:

Note Note

Tracing is processing-intensive and space-intensive - We recommend that you do not turn tracing on for more than one client at a time.


  • On Windows Vista and Windows Server 2008 operating systems, only Administrators and SYSTEM accounts can use tracing. To run tracing on a client, you must choose the option run as Administrator. To run tracing on the server, the AOS account must be a SYSTEM account.

  • The log directory cannot be changed - The log is always installed to installationdirectory\log. Restrict access to the directory to administrators and the AOS account (the domain account or Network Service account associated with the AOS service).

  • Trace files are stored in binary format, and can be read with the Microsoft Dynamics AX Tracing Utility.

Set tracing options (Server)

  1. Open the Server Configuration utility ( Start> Administrative Tools> Microsoft Dynamics AX Server Configuration Utility).

  2. Verify that the currently selected Application Object Server (AOS) instance and configuration are the ones you want to modify.

  3. On the Tracingtab, evaluate the type of tracing you need to do, and choose settings.

    To do this

    Select these options

    Monitor general performance on a production server

    RPC round trips to server

    Perform standard troubleshooting

    RPC round trips to server

    X++ method calls, Number of nested calls: 4

    SQL statements

    Allow client tracing on Application Object Server instance

    Debug code

    RPC round trips to server

    X++ methods

    SQL statements

    Row fetch summary (count and time)

    Allow client tracing on Application Object Server instance

    Deep troubleshooting

    All options. Performance may be degraded while all tracing options are on.

  4. On the Tracingtab, click Start trace. If the AOS Windows service is running, the trace starts within 15 seconds. If the service is stopped, the trace starts the next time the service is started.

Set tracing options (Client)

  1. Open the Configuration utility ( Start> Control Panel> Administrative Tools> Microsoft Dynamics AX Configuration Utility).

  2. Verify that the currently selected configuration is the one you want to modify.

  3. On the Tracingtab, evaluate the type of tracing you need to do, and choose settings.

    To do this

    Select these options

    Monitor general performance on a production server

    RPC round trips to server

    Perform standard troubleshooting

    RPC round trips to server

    X++ method calls, Number of nested calls: 4

    SQL statements

    Debug code

    RPC round trips to server

    X++ methods

    SQL statements

    Row fetch summary (count and time)

    Enable method tracing to client desktop

    Deep troubleshooting

    All options. Performance may be degraded while all tracing options are on.

  4. To start tracing once you have set the options you want, close the Configuration Utility, and restart your Microsoft Dynamics AX client.

View a trace file

Files from traces are saved to the following locations:

Type of trace

Location

AOS trace files

AOS computer Log\<servername>_<timestamp>.trc

AOS settings and SQL settings triggered from client ( Allow client tracing on Application Object Server instanceis selected)

AOS computer Log\<Username>_<ClientIP>_<sessionID>_<server>.trc

Client method trace triggered from client ( Enable method tracing to client desktopis selected)

Client computer log\<Username>_<ClientIP>_<sessionID>_<client>.trc

A new file is created each time tracing is started, or when a new day starts.

Note Note

If you are running frequent traces, be sure to remove or archive unneeded trace files often.


Troubleshooting tracing

This section provides information on troubleshooting issues encountered while tracing.

In the Configuration Utility it appears that a trace is running, but when I look in Windows, the trace is not running

When a trace file reaches its size limit, it is stopped by Windows. The Configuration Utility interface does not synchronize with Windows until you click Stop trace.

When I run more than one client tracing session at a time, my system slows down

Tracing is processing-intensive and space-intensive - we recommend that you do not turn tracing on for more than one client at a time.

See Also