Natura deficit, fortuna mutatur, deus omnia cernit.  


WebSphere MQ traces
Other useful traces

URL


OS/400 trace

The WebSphere MQ for OS/400 Trace

  1. Remove old trace files using the following command:

    RMVLNK OBJLNK('/qibm/userdata/mqm/trace/*.*')

  2. To start trace; issue the following command from the command line:

    TRCMQM TRCEARLY(*NO) SET(*ON)TRCLEVEL(*DETAIL) MQMNAME(QMANAGER_NAME)

    NOTE: Use TRCEARLY *YES for problems with CRTMQM and STRMQM.

  3. Recreate failure/problem.

  4. To end trace; issue the following command from the command line:

    TRCMQM TRCEARLY(*NO) SET(*OFF) MQMNAME(QMANAGER_NAME)

    NOTE: If TRCEARLY(*YES) was specified at the start of trace, then it MUST be specified on termination.

  5. Formatting is not required.

  6. To save all unformatted trace files to a savefile:

    CRTSAVF FILE(QGPL/PNNNNNTRC) TEXT('Save file for PMR Pnnnnn') SAV DEV('/qsys.lib/qgpl.lib/pnnnnntrc.file') OBJ(('/qibm/userdata/mqm/trace' *INCLUDE))

    where nnnnn is the pmr number


z/OS trace

The MQSC commands in the instructions below are prefixed with "/cpf ", where cpf is the command prefix defined for the subsystem.

z/OS GTF Trace

Follow the instructions listed below to start, stop and format WebSphere MQ for OS/390 GTF trace.

For additional details regarding trace, refer to the publication: WebSphere MQ for z/OS Problem Determination Guide.


z/OS MSTR internal trace

Follow the instructions listed below to start, stop and format WebSphere MQ for z/OS MSTR Internal trace.

For additional details regarding trace, refer to the publication: WebSphere MQ for z/OS Problem Determination Guide

When searching for RCs and CCs in FMT files, keep in mind they are written in Hex, this is d'2035 is x'07F3, and d'2085 is x'0825. Gracias, Dani ! [03-2009]


z/OS CHIN trace

Follow the instructions listed below to start, stop and format WebSphere MQ for z/OS CHIN trace.

For additional details regarding trace, refer to the publication: WebSphere MQ for z/OS Problem Determination Guide


z/OS System SSL trace

If you are diagnosing a problem with the keyring read by SSL, then the trace MUST be started just prior to the channel initiator. Otherwise the required trace information will not be collected.

If you are diagnosing a problem with the certificate exchange during the channel handshake then the trace MUST be started just prior to the secure channel being started; otherwise the required trace information will not be collected.

Refer to the z/OS System SSL Programming manual


AIX trace

Follow the instructions listed below to start, stop and format the AIX trace on V5.3.

Note: WebSphere MQ 6.0 customers should review the second part of this section. The additional trace function described in part two is only available at WebSphere MQ V6.0.

For additional details regarding trace, refer to the publication: WebSphere MQ System Administration Guide

Full information on AIX trace options is available in the General Programming Concepts: Writing and Debugging Programs


WebSphere MQ for AIX race V6.0

Follow the instructions listed below to start, stop and format WebSphere MQ for AIX trace. Trace files are written to the directory /var/mqm/trace, so delete or relocate old trace files before beginning a new trace.

For additional details regarding trace, refer to the publication WebSphere MQ System Administration Guide


HP-UX race

Follow the instructions listed below to start, stop and format WebSphere MQ for HP-UX trace. Trace files are written to the directory /var/mqm/trace/, so delete or relocate old trace files before beginning a new trace.

For additional details regarding trace, refer to the publication: WebSphere MQ System Administration Guide


WebSphere MQ for HP OpenVMS trace

For further details see WebSphere MQ for HP OpenVMS System Administration Guide, Chapter 14, Using WebSphere MQ trace.


WebSphere MQ for HP NSS trace

For further details see: WebSphere MQ for HP NonStop Server: System Administration Guide, Chapter 16, Tracing


Linux trace

Follow the instructions listed below to start, stop and format WebSphere MQ for Linux trace. Trace files are written to the directory /var/mqm/trace/, so delete or relocate old trace files before beginning a new trace.

For additional details regarding trace, refer to the publication: WebSphere MQ System Administration Guide.


Solaris trace

Follow the instructions listed below to start, stop and format WebSphere MQ for Solaris trace. Trace files are written to the directory /var/mqm/trace/, so delete or relocate old trace files before beginning a new trace.

For additional details regarding trace, refer to the publication: WebSphere MQ System Administration Guide.


Windows trace

Follow the instructions listed below to start, stop and format WebSphere MQ for Windows trace.

For additional details regarding trace, refer to the publication: WebSphere MQ System Administration Guide.

Complete script

A complete script shall look like this one :

echo +++ deixar rastre del processos actuals tasklist > tsklist.txt echo +++ engegar trassa strmqtrc -t all echo +++ pulsa INTRO quan acabis pause clear echo +++ aturem la trassa endmqtrc echo +++ a veure quins fitxers ens interessen type AMQ* | find "MQCONN" | more

WebSphere MQ for Windows v6.0 Explorer trace

Follow the instructions listed below to run trace for the WebSphere MQ for Windows v6.0 Explorer using the MQ Java API.

  1. Modify the files runmqcfg.cmd and runmqcfg_rcp.cmd in the directory C:\Program Files\IBM\WebSphere MQ\bin

    Add the following line, which specifies the properties file in C:\TEMP\internal.properties

    set AMQ_EXPLORER=%AMQ_EXPLORER% "-Dcom.ibm.mq.commonservices=C:\TEMP\internal.properties"

    Note: The command must be typed on ONE LINE in the runmqcfg.cmd and runmqcfg_rcp.cmd files and BEFORE the statement:

    start "WebSphere MQ Explorer" %AMQ_EXPLORER%

  2. Create a file internal.properties in the C:\TEMP directory as with the following text:

    Diagnostics.MQ=enabled Diagnostics.Java=explorer,wmqjavaclasses,all #Diagnostics.Java=explorer Diagnostics.Java.Trace.Detail=high Diagnostics.Java.Trace.Destination.File=enabled Diagnostics.Java.Trace.Destination.Console=disabled Diagnostics.Java.Trace.Destination.Pathname=C:\\temp\\trace Diagnostics.Java.FFDC.Destination.Pathname=C:\\temp\\FFDC Diagnostics.Java.Errors.Destination.Filename=C:\\temp\\errors\\AMQJERR.LOG

  3. You may also need to create the following directories:

    C:\temp\FFDC C:\temp\trace C:\temp\errors

  4. In the C:\temp\trace directory you will find files with the format AMQyyyymmddhhmmsssss.*.TRC which contain the MQ Java trace output.

WebSphere MQ for Linux v6.0 Explorer trace

Follow the instructions listed below to run trace for the WebSphere MQ for Linux v6.0 Explorer using the MQ Java API.

  1. Modify the files runmqcfg.cmd and runmqcfg_rcp.cmd in the directory:

    /opt/mqm/bin

    Modify the line:

    AMQ_EXPLORER="./eclipse" to AMQ_EXPLORER="/opt/mqm/ies30/eclipse/eclipse"

    And add the single line:

    AMQ_EXPLORER="$AMQ_EXPLORER -Dcom.ibm.mq.commonservices=/tmp/internal.properties" before the statement cd $AMQECLIPSE

  2. Both of these scripts are dependent on the environment variable AMQECLIPSE. If this environment variable does not exist then it should be created as the first line in the script. For example:

    export AMQECLIPSE="/opt/mqm/ies30/eclipse"

    Note: If you want, you can include the above line in the user's profile.

  3. Create a file called "internal.properties" in the /tmp directory with the following text.

    Diagnostics.MQ=enabled Diagnostics.Java=explorer,wmqjavaclasses,all #Diagnostics.Java=explorer Diagnostics.Java.Trace.Detail=high Diagnostics.Java.Trace.Destination.File=enabled Diagnostics.Java.Trace.Destination.Console=disabled Diagnostics.Java.Trace.Destination.Pathname=/tmp/trace Diagnostics.Java.FFDC.Destination.Pathname=/tmp/FFDC Diagnostics.Java.Errors.Destination.Filename=/tmp/errors/AMQJERR.LOG

  4. Ensure that the file permissions for the above file allow it to be read by all processes:

    chmod a+r /tmp/internal.properties

  5. You may also need to create the following directories:

    /tmp/FFDC /tmp/trace /tmp/errors

  6. Ensure that the file permissions for these directories allow other users to write, such as:

    chmod 777 /tmp/FFDC chmod 777 /tmp/trace chmod 777 /tmp/errors

  7. From a command prompt, invoke the script:

    runmqcfg

  8. In the /tmp/trace directory you will find files with the format AMQyyyymmddhhmmsssss.*.TRC which contain the MQ Java trace output.


WebSphere MQ Base Java Class trace

Follow the instructions listed below to start, stop and format trace for the WebSphere MQ base Java classes.

For additional details regarding trace, refer to the publication: WebSphere MQ Using Java.


WebSphere MQ JMS trace

Follow the instructions listed below to start, stop and format JMS trace.

For additional details regarding trace, refer to the publication: WebSphere MQ Using Java.


WebSphere MQ JCA Resource Adapter trace

For details on how to enable JCA Resource adapter trace, refer to the WebSphere MQ Using Java manual. The ra.xml file provided with the 6.0.2.1 resource adapter has these properties defined, so they just need editing to enable trace..

Note : MQ JMS/Java trace needs enabling as above, how this is done will depend on the application server in use. Two files will need collecting mqjms.trc from the JMS client, and the trace file created by the JCA RA.


WebLogic Server Version 8.1 JMS Trace

Follow the instructions listed below to enable JMS trace under WebLogic.


WebSphere Application Server JMS trace

Enabling JMS trace for releases of WebSphere Application Server


MQ Client Trace Instructions

IMS trace

Note: You must switch the OLDS/OLPS in IMS and save the one that contains current IMS trace. If OLDS/OLPS too big, then cut 6701 recs and send those.


Amunt! Top Amunt!
Links

MS0P - provides a mechanism to format Event messages and to aggregate the Statistics and Accounting reports generated by MQ.
The SupportPac also implements the Trace Route function, reporting on the route that messages take through a network.

MH06 - provides simple command line tools (mqtrcfrmt, mqoptions, and mqapitrcstats) to aid in using MQ traces


Updated 20150520