Using trace on Windows

Use the strmqtrc and endmqtrc commands or the IBM® WebSphere® MQ Explorer interface to start and end tracing.

Windows uses the following commands for the client trace facility:
strmqtrc
to start tracing
endmqtrc
to end tracing

The output files are created in the MQ_DATA_PATH/trace directory.

Trace files on IBM WebSphere MQ for Windows

Trace files are named AMQppppp.qq.TRC where the variables are:
ppppp
The ID of the process reporting the error.
qq
A sequence number, starting at 0. If the full file name exists, this value is incremented by one until a unique trace file name is found. A trace file name can exist if a process is reused.
Note:
  1. The process identifier can contain fewer, or more, digits than shown in the example.
  2. There is one trace file for each process running as part of the entity being traced.

To format or view a trace file, you must be either the creator of the trace file, or a member of the mqm group.

SSL trace files have the names AMQ.SSL.TRC and AMQ.SSL.TRC.1. You cannot format SSL trace files; send them unchanged to IBM support.

How to start and stop a trace

Enable or modify tracing using the strmqtrc control command (see strmqtrc). To stop tracing, use the endmqtrc control command (see endmqtrc).

In IBM WebSphere MQ for Windows systems, you can also start and stop tracing using the IBM WebSphere MQ Explorer, as follows:
  1. Start the IBM WebSphere MQ Explorer from the Start menu.
  2. In the Navigator View, right-click the WebSphere MQ tree node, and select Trace.... The Trace Dialog is displayed.
  3. Click Start or Stop as appropriate.

Selective component tracing

Use the -t and -x options to control the amount of trace detail to record. By default, all trace points are enabled. You can specify the points that you do not want to trace using the -x option. So if, for example, you want to trace only data flowing over communications networks, use:
strmqtrc -x all -t comms 
For detailed information about the trace command, see strmqtrc.

Selective process tracing

Use the -p option of the strmqtrc command control to restrict trace generation to specified named processes. For example, to trace all threads that result from any running process called amqxxx.exe, use the following command:
strmqtrc -p amqxxx.exe
For detailed information about the trace command, see strmqtrc.