IBM Support

IT31236: IBM MQ Client could hit deadlock when dynamically enabling trace

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • If there is a jmqi exception when enabling MQ client trace, due
    to a timing issue,  a deadlock can happen.
    This problem has been found in MQ 8.0 and MQ 9.0
    

Local fix

  • Avoid enabling the Trace if possible.
    

Problem summary

  • ****************************************************************
    USERS AFFECTED:
    This issue affects users of the MQ Java Client application when
    enabling Trace dynamically.
    
    
    Platforms affected:
    MultiPlatform
    
    ****************************************************************
    PROBLEM DESCRIPTION:
    When enabling Java Client Trace it is possible that the java
    application on which the Trace is being enable could get stuck
    in a DEADLOCK condition.  This would prevent all threads from
    being able to progress.  This issue will not show any external
    messages or error, the only means to confirm this would be to
    look to capture javacore(kill -3 <Application JVM Process ID>.
     Then look to check the stacks, you should see some similar to
    the following:
    
    < "HAR.19064887.Thread":
    <    at
    com.ibm.mq.jmqi.JmqiException.initializeClass(JmqiException.java
    :257)
    <    - waiting to lock <0xfffffffcec98eb20> (a java.lang.Class
    for com.ibm.mq.jmqi.JmqiException)
    <    at
    com.ibm.mq.jmqi.JmqiException.<init>(JmqiException.java:245)
    <    at
    com.ibm.mq.jmqi.local.LocalMQ$4.<init>(LocalMQ.java:1268)
    <    at com.ibm.mq.jmqi.local.LocalMQ.loadLib(LocalMQ.java:1268)
    <    at com.ibm.mq.jmqi.local.LocalMQ$1.run(LocalMQ.java:309)
    <    at java.security.AccessController.doPrivileged(Native
    Method)
    <    at
    com.ibm.mq.jmqi.local.LocalMQ.initialise_inner(LocalMQ.java:259)
    <    at
    com.ibm.mq.jmqi.local.LocalMQ.initialise(LocalMQ.java:221)
    <    - locked <0xfffffffcf10dfc18> (a java.lang.Object)
    <    at com.ibm.mq.jmqi.local.LocalMQ.<init>(LocalMQ.java:1350)
    <    at
    com.ibm.mq.jmqi.local.LocalServer.<init>(LocalServer.java:230)
    <    at
    sun.reflect.GeneratedConstructorAccessor618.newInstance(Unknown
    Source)
    <    at
    sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delega
    tingConstructorAccessorImpl.java:45)
    <    at
    java.lang.reflect.Constructor.newInstance(Constructor.java:526)
    <    at
    com.ibm.mq.jmqi.JmqiEnvironment.getInstance(JmqiEnvironment.java
    :706)
    <    at
    com.ibm.mq.jmqi.JmqiEnvironment.getMQI(JmqiEnvironment.java:640)
    <    - locked <0xfffffffcea0b55f8> (a java.util.HashMap)
    <    at
    com.ibm.msg.client.wmq.factories.WMQComponent.getImplementationI
    nfo(WMQComponent.java:273)
    <    at
    com.ibm.msg.client.commonservices.trace.Trace.getVersion(Trace.j
    ava:2098)
    <    at
    com.ibm.msg.client.commonservices.trace.Trace.setOn(Trace.java:6
    00)
    <    - locked <0xfffffffce042a270> (a java.lang.Class for
    com.ibm.msg.client.commonservices.trace.Trace)
    <    at
    com.ibm.mq.MQEnvironment.enableTracing(MQEnvironment.java:683)
    ...
    <    at java.lang.Thread.run(Thread.java:745)
    < "RcvThread:
    com.ibm.mq.jmqi.remote.impl.RemoteTCPConnection@395580088[qmid=Q
    M1,fap=13,channel=MQC1
    <    at
    com.ibm.msg.client.commonservices.trace.Trace.getCachedClassObje
    ct(Trace.java:1418)
    <    - waiting to lock <0xfffffffce042a270> (a java.lang.Class
    for com.ibm.msg.client.commonservices.trace.Trace)
    <    at
    com.ibm.msg.client.commonservices.trace.Trace.methodEntryInterna
    l(Trace.java:797)
    <    at
    com.ibm.msg.client.commonservices.trace.Trace.entry(Trace.java:7
    72)
    <    at
    com.ibm.mq.jmqi.JmqiException.initializeClass(JmqiException.java
    :258)
    <    - locked <0xfffffffcec98eb20> (a java.lang.Class for
    com.ibm.mq.jmqi.JmqiException)
    <    at
    com.ibm.mq.jmqi.JmqiException.<init>(JmqiException.java:245)
    <    at
    com.ibm.mq.jmqi.remote.impl.RemoteTCPConnection.receive(RemoteTC
    PConnection.java:1677)
    <    at
    com.ibm.mq.jmqi.remote.impl.RemoteRcvThread.receiveBuffer(Remote
    RcvThread.java:733)
    <    at
    com.ibm.mq.jmqi.remote.impl.RemoteRcvThread.receiveOneTSH(Remote
    RcvThread.java:699)
    <    at
    com.ibm.mq.jmqi.remote.impl.RemoteRcvThread.run(RemoteRcvThread.
    java:138)
    <    at
    com.ibm.msg.client.commonservices.workqueue.WorkQueueItem.runTas
    k(WorkQueueItem.java:314)
    <    at
    com.ibm.msg.client.commonservices.workqueue.SimpleWorkQueueItem.
    runItem(SimpleWorkQueueItem.java:99)
    <    at
    com.ibm.msg.client.commonservices.workqueue.WorkQueueItem.run(Wo
    rkQueueItem.java:338)
    <    at
    com.ibm.msg.client.commonservices.workqueue.WorkQueueManager.run
    WorkQueueItem(WorkQueueManager.java:312)
    <    at
    com.ibm.msg.client.commonservices.j2se.workqueue.WorkQueueManage
    rImplementation$ThreadPoolWorker.run(WorkQueueManagerImplementat
    ion.java:1227)
    <
    < Found 1 deadlock.
    

Problem conclusion

  • The code has been changed to prevent the deadlock occurring.
    
    ---------------------------------------------------------------
    The fix is targeted for delivery in the following PTFs:
    
    Version    Maintenance Level
    v8.0       8.0.0.15
    v9.0 LTS   9.0.0.10
    v9.1 CD    9.1.5
    
    The latest available maintenance can be obtained from
    'WebSphere MQ Recommended Fixes'
    http://www-1.ibm.com/support/docview.wss?rs=171&uid=swg27006037
    
    If the maintenance level is not yet available information on
    its planned availability can be found in 'WebSphere MQ
    Planned Maintenance Release Dates'
    http://www-1.ibm.com/support/docview.wss?rs=171&uid=swg27006309
    ---------------------------------------------------------------
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT31236

  • Reported component name

    IBM MQ BASE MP

  • Reported component ID

    5724H7251

  • Reported release

    800

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2019-12-11

  • Closed date

    2020-01-28

  • Last modified date

    2020-01-28

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    IBM MQ BASE MP

  • Fixed component ID

    5724H7251

Applicable component levels

[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSYHRD","label":"IBM MQ"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.0.0.0","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
28 January 2020