endmqtrc (end trace)

End trace for some or all of the entities that are being traced.


Purpose

Use the endmqtrc command to end tracing for the specified entity or all entities. The endmqtrc command ends only the trace that is described by its parameters. Using endmqtrc with no parameters ends early tracing of all processes.

All endmqtrc commands set the type of output to mqm on strmqtrc.

Attention: There can be a slight delay between the endmqtrc command ending, and all trace operations actually completing. This is because IBM MQ processes are accessing their own trace files. As each process becomes active at different times, their trace files close independently of one another.


Syntax

The syntax of this command is as follows:

endmqtrc   -m QMgrName  -i PidTids  -p Apps  -e   -a


Optional parameters

    -m QMgrName
    The name of the queue manager for which to end tracing. This parameter applies to server products only.

    The QMgrName supplied must match exactly the QMgrName supplied on the strmqtrc command. If the strmqtrc command used wildcards, the endmqtrc command must use the same wildcard specification including the escaping of any wildcard characters to prevent them being processed by the command environment.

    A maximum of one -m flag and associated queue manager name can be supplied on the command.

    -i PidTids
    Process identifier (PID) and thread identifier (TID) for which to end tracing. We cannot use the -i flag with the -e flag. If you try to use the -i flag with the -e flag, then an error message is issued. This parameter must only be used under the guidance of IBM Service personnel.
    -p Apps
    The named processes for which to end tracing. Apps is a comma-separated list. You must specify each name in the list exactly as the program name would be displayed in the "Program Name" FDC header. Asterisk (*) or question mark (?) wildcards are allowed. We cannot use the -p flag with the -e flag. If you try to use the -p flag with the -e flag, then an error message is issued.
    -e
    Ends early tracing of all processes.

    Use endmqtrc with no parameters has the same effect as endmqtrc -e. We cannot specify the -e flag with the -m flag, the -i flag, or the -p flag.

    -a
    Ends all tracing. Important: This flag must be specified alone.


Return codes

Return code Description
AMQ5611 This message is issued if you supply invalid arguments to the command.
58 Inconsistent use of installations detected


Examples

This command ends tracing of data for a queue manager called QM1.
endmqtrc -m QM1
The following examples are a sequence that shows how the endmqtrc command ends only the trace that is described by its parameters.
  1. The following command enables tracing for queue manager QM1 and process amqxxx.exe:
    strmqtrc -m QM1 -p amqxxx.exe
    
  2. The following command enables tracing for queue manager QM2:
    strmqtrc -m QM2
    
  3. The following command ends tracing for queue manager QM2 only. Tracing of queue manager QM1 and process amqxxx.exe continues:
    endmqtrc -m QM2
    


Related commands

Command Description
dspmqtrc Display formatted trace output
strmqtrc (Start trace) Start trace