IBM Support

PH32163: DEADLOCK CONDITION IN MEMORY SESSION AND LOGGING CONSOLE HANDLER

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

  • Deadlock in
    com/ibm/ws/session/store/memory/MemorySession and
    java/util/logging/ConsoleHandler
    
    Customer send in the latest traces and javacore after disabled
    WSLogger logger by
    setting"com.ibm.ws.logging.WsLoggerConfigurator=off" in the
    trace specification.
    
    The Deadlock is because two separate objects are synchronized.
    
    One thread has a lock on one (MemorySession) and is requesting a
    lock on the other (WsLogger) whereas the other thread has a lock
    on the second object (WsLogger) and is requesting a lock on the
    first one (MemorySession).
    
    Servlet supports concurrent access to a session, therefore
    MemorySession update is locked. The deadlock occurs because the
    session manager does not expect the use of more than one locking
    mechanism.
    
    Thread Name : WebContainer : 3
    State : Deadlock/Blocked
    
    Owns Monitor Lock on
    java/util/logging/ConsoleHandler@0x0000000605AE70D0
    
    Waiting for Monitor Lock on
    com/ibm/ws/session/store/memory/MemorySession@0x00000006062B9D20
    
    Java Stack :
    at
    com/ibm/ws/session/store/memory/MemorySession.toString(MemorySes
    sion.java:662)
    at
    java/text/MessageFormat.subformat(MessageFormat.java:1291(Compil
    ed Code))
    at
    java/text/MessageFormat.format(MessageFormat.java:876(Compiled
    Code))
    at java/text/Format.format(Format.java:168(Compiled Code))
    at
    java/text/MessageFormat.format(MessageFormat.java:852(Compiled
    Code))
    at
    java/util/logging/Formatter.formatMessage(Formatter.java:149(Com
    piled Code))
    at
    java/util/logging/SimpleFormatter.format(SimpleFormatter.java:16
    2(Compiled Code))
    at
    java/util/logging/StreamHandler.publish(StreamHandler.java:222(C
    ompiled Code))
    at
    java/util/logging/ConsoleHandler.publish(ConsoleHandler.java:127
    (Compiled Code))
    at java/util/logging/Logger.log(Logger.java:749(Compiled Code))
    at
    com/ibm/ws/logging/WsLogger.deliverOrBuffer(WsLogger.java:422(Co
    mpiled Code))
    at com/ibm/ws/logging/WsLogger.log(WsLogger.java:400(Compiled
    Code))
    at com/ibm/ws/logging/WsLogger.logp(WsLogger.java:638(Compiled
    Code))
    at
    com/ibm/ws/logging/WsLogger.exiting(WsLogger.java:813(Compiled
    Code))
    at
    com/ibm/ws/session/store/memory/MemoryStore.getSession(MemorySto
    re.java:197)
    at
    com/ibm/ws/session/store/memory/MemoryStore.getSession(MemorySto
    re.java:717)
    at
    com/ibm/ws/session/SessionManager.getSessionFromStore(SessionMan
    ager.java:500)
    at
    com/ibm/ws/session/SessionManager.getSession(SessionManager.java
    :479)
    at
    com/ibm/ws/session/SessionManager.getSession(SessionManager.java
    :465)
    at
    com/ibm/ws/session/SessionManager.getSession(SessionManager.java
    :696)
    at
    com/ibm/ws/session/SessionContext.getIHttpSession(SessionContext
    .java:474)
    at
    com/ibm/ws/session/SessionContext.sessionPreInvoke(SessionContex
    t.java:636)
    at
    com/ibm/ws/webcontainer/srt/SRTRequestContext.sessionPreInvoke(S
    RTRequestContext.java:64)
    at com/ibm/ws/webcontainer/webapp
    ...
    
    Thread Name : WebContainer : 0
    
    State : Deadlock/Blocked
    
    Owns Monitor Lock on
    com/ibm/ws/session/store/memory/MemorySession@0x00000006062B9D20
    
    Waiting for Monitor Lock on
    java/util/logging/ConsoleHandler@0x0000000605AE70D0
    
    Java Stack :
    
    at
    java/util/logging/StreamHandler.publish(StreamHandler.java:217(C
    ompiled Code))
    at
    java/util/logging/ConsoleHandler.publish(ConsoleHandler.java:127
    (Compiled Code))
    at java/util/logging/Logger.log(Logger.java:749(Compiled Code))
    at
    com/ibm/ws/logging/WsLogger.deliverOrBuffer(WsLogger.java:422(Co
    mpiled Code))
    at com/ibm/ws/logging/WsLogger.log(WsLogger.java:400(Compiled
    Code))
    at com/ibm/ws/logging/WsLogger.logp(WsLogger.java:638(Compiled
    Code))
    at
    com/ibm/ws/logging/WsLogger.entering(WsLogger.java:766(Compiled
    Code))
    at
    com/ibm/ws/session/store/memory/MemorySession.getAttribute(Memor
    ySession.java:431(Compiled Code))
    at
    com/ibm/ws/session/http/HttpSessionImpl.getAttribute(HttpSession
    Impl.java:192(Compiled Code))
    at
    com/ibm/ws/session/SessionData.getSessionValue(SessionData.java:
    307(Compiled Code))
    at
    com/ibm/ws/session/SessionData.getAttribute(SessionData.java:163
    (Compiled Code))
    at
    com/ibm/ws/session/HttpSessionFacade.getAttribute(HttpSessionFac
    ade.java:139(Compiled Code))
    at
    ilog/rules/teamserver/web/beans/ManagerBean.getCurrentManager(Ma
    nagerBean.java:1932)
    at
    com/ibm/_jsp/_progressStatus._jspService(_progressStatus.java:10
    5)
    at
    com/ibm/ws/jsp/runtime/HttpJspBase.service(HttpJspBase.java:99)
    at javax/servlet/http/HttpServlet.service(HttpServlet.java:668)
    

Local fix

  • N/A
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:  All users of IBM WebSphere Application      *
    *                  Server                                      *
    ****************************************************************
    * PROBLEM DESCRIPTION: Enable logging for session may cause    *
    *                      deadlock with session manager           *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    Synchronized code in WsLogger can caused deadlock in
    concurrent session method calls
    

Problem conclusion

  • Code changes were made to synchronize session objects
    instead of synchronize session methods.
    
    The fix for this APAR is targeted for inclusion in fix pack
    8.5.5.20 and 9.0.5.8.
    For more information, see 'Recommended Updates for WebSphere
    Application Server':
    https://www.ibm.com/support/pages/node/715553
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH32163

  • Reported component name

    WEBS APP SERV N

  • Reported component ID

    5724H8800

  • Reported release

    850

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2020-11-30

  • Closed date

    2021-03-02

  • Last modified date

    2021-03-02

  • 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

    WEBS APP SERV N

  • Fixed component ID

    5724H8800

Applicable component levels

  • R850 PSY

       UP

  • R900 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.5","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
02 November 2021