IBM Support

Collect IBM MQ MustGather data to solve Java and JMS problems on Linux, UNIX, Windows, IBM i and HP Integrity NonStop Server

Troubleshooting


Problem

An MQ Java™ or Java Message Service (JMS) application is failing, and you need to collect MustGather data to find a solution.

Environment

These instructions apply only to IBM MQ V9.0 and V8.0, and WebSphere MQ V7.5, V7.1, V7.0 and V6.0 on AIX, HP-UX, Linux, Solaris and Windows, to IBM MQ V9.0 and V8.0, and WebSphere MQ V7.1, V7.0 and V6.0 on IBM i, and to the IBM MQ V8.0 and WebSphere MQ V7.1 clients for HP Integrity NonStop Server. Refer to the IBM MQ Read First page for instructions on other operating systems:






Resolving The Problem

Please answer these questions about the problem and then follow the steps below:

  • What Java or JMS problem did you observe on the system?
  • What time did the Java or JMS problem start and when did it stop?
  • Were any Java exceptions reported, and did they include a Java call stack?
  • Which queue managers, queues and topics does the Java or JMS application use?


Step 1: Generate Data


It is essential to gather information from the system when the Java or JMS problem is happening in order to identify the cause:




  1. Generate an MQ classes for Java trace or a Java Message Service trace, depending on whether your application uses the MQ Java or JMS interface. If your application is running under WebSphere Application Server, follow the trace instructions for that environment.


  2. If the Java or JMS application is receiving an unexpected error from a remote queue manager, generate a simultaneous MQ trace of that queue manager:




Step 2: Collect Data


  1. If your application is running in WebSphere Application Server, use its collector tool to gather information about the application server and its configuration, JNDI definitions, ffdc files, logs, and any traces generated in Step 1 above:



  2. For applications running in other Java application servers or Java SE environments, collect the following files:

    1. The standard output stream data (e.g. System.out or similar files).

    2. The standard error stream data (e.g. System.err or similar files).

    3. The Java virtual machine log files (e.g. native_stdout.log and native_stderr.log or similar files).

    4. The mqjms.log file, found by default in the application's current working directory.l

    5. The mqjms_PID.trc file, named for the process ID of the Java virtual machine, found in the same directory.

    6. Any FFST files found in the FFDC subdirectory of the application's current working directory.



  3. Place the Java or JMS traces and logs from Steps 1 and 2, and where applicable the WebSphere Application Server collector, in the top-level MQ errors directory. Both the runmqras automation tool and the manual collection steps below collect files found there.


  4. Collect data automatically with the runmqras command if you are running IBM MQ V9.0 or V8.0, or WebSphere MQ V7.5, V7.1.0.1 or later, or V7.0.1.8 or later. Be sure to collect the runmqras trace section, and from queue managers the defs and topic sections as well, and to specify your PMR number:

    1. Collecting runmqras output from queue manager QMA


      runmqras -section defs,topic,trace -qmlist QMA -pmrno 12345,67R,890

      Collecting runmqras output from a client


      runmqras -section trace -pmrno 12345,67R,890


  5. Alternatively, collect the MQ data manually.

    Collecting MQ data manually


    1. If your system has more than one MQ installation, use the setmqenv command to choose the one with the problem before proceeding:

      Linux and UNIX


      sh> . /path/to/mqm/bin/setmqenv -n InstallationX

      Windows


      C:\> "C:\Program Files\IBM\MQ\bin\setmqenv" -n InstallationX


    2. Record the MQ version and maintenance level.


    3. Record the operating system version and maintenance level.


    4. Save the MQ configuration information, for example registry keys and ini files.


    5. If your system has more than one MQ installation, record your MQ installation details:

      Linux and UNIX


      sh> dspmqinst > /tmp/dspmqinst.txt

      Windows


      C:\> dspmqinst > %TEMP%/dspmqinst.txt


    6. On MQ V7.1 and later server installations, use dmpmqcfg to record the queue manager configuration:

      Linux and UNIX


      sh> dmpmqcfg -m QMA > /tmp/QMA.config.txt

      Windows


      C:\> dmpmqcfg -m QMA > %TEMP%\QMA.config.txt

      IBM i Qshell


      ===> /QSYS.LIB/QMQM.LIB/DMPMQCFG.PGM -m QMA > /tmp/QMA.config.txt


    7. Otherwise, on MQ server V7.0 and earlier server installations, use runmqsc to record the queue manager configuration. If any command gives an error, carry on with the others:

      DISPLAY QMGR ALL
      DISPLAY Q(*) ALL
      DISPLAY SUB(*) ALL
      DISPLAY TOPIC(*) ALL
      DISPLAY CHANNEL(*) ALL
      DISPLAY SERVICE(*) ALL
      DISPLAY PROCESS(*) ALL
      DISPLAY LISTENER(*) ALL
      DISPLAY NAMELIST(*) ALL


    8. On all MQ server installations, use runmqsc to record status information from the queue manager. If any command gives an error, carry on with the others:

      DISPLAY PUBSUB ALL
      DISPLAY QMSTATUS ALL
      DISPLAY CHSTATUS(*) ALL
      DISPLAY LSSTATUS(*) ALL
      DISPLAY SVSTATUS(*) ALL
      DISPLAY SBSTATUS(*) ALL
      DISPLAY CONN(*) TYPE(*) ALL
      DISPLAY QSTATUS(*) TYPE(QUEUE) ALL
      DISPLAY QSTATUS(*) TYPE(HANDLE) ALL
      DISPLAY TPSTATUS('#') TYPE(PUB) ALL
      DISPLAY TPSTATUS('#') TYPE(SUB) ALL
      DISPLAY TPSTATUS('#') TYPE(TOPIC) ALL


    9. If your Java or JMS application is having difficulty connecting to a remote queue manager, use your operating system tools to list network connections on both sides immediately before and after the connection attempt:

      Displaying network connections on Linux and UNIX


      sh> netstat -an

      Displaying network connections on Windows


      C:\> NETSTAT -AN

      Displaying IPv4 and IPv6 network connections at the IBM i Command Line


      ===> NETSTAT OPTION(*CNN)
      ===> NETSTAT OPTION(*CNN6)

      Displaying network connections on HP OpenVMS


      $ MCR SYS$SYSTEM:TCPIP$NETSTAT -an


    10. Manually package your files for IBM, including files containing the output from the commands listed in Step 1 and 2.


Step 3: Send Data to IBM


  1. Send your data to the IBM ECuRep repository by email to websphere_support@ecurep.ibm.com, by standard or secure HTTP or FTP. or by using the IBM Secure Diagnostic Data Upload Utility (SDDUU) Java application.


  2. While the data is transferring, send an email or use the IBM Service Request tool to update your PMR with your description of the problem and of the data you are sending.



  3. Contact your country representative if you need to speak to an IBM technical support representative, or in the US call 1-800-IBM-SERV. Refer to the IBM Software Support Handbook for more information on working with IBM.


[{"Product":{"code":"SSFKSJ","label":"WebSphere MQ"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Problem Determination","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF012","label":"IBM i"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"9.0;8.0;7.5;7.1;7.0;6.0","Edition":"All Editions","Line of Business":{"code":"LOB45","label":"Automation"}}]

Product Synonym

IBMMQ WebSphere MQ WMQ

Document Information

Modified date:
22 June 2018

UID

swg21290340