My Services WebSphere Training | JEE Build & Deploy | Automatic Linux Provisioning
Tools ..
IBM Thread and Monitor Dump Analyzer for Java (JCA)
Installing JCA
To install JCA unzip the jca31.zip file to a directory. You should have a Windows script file “runjca.cmd”. This script starts the tool. You may need to edit the script to point at you jvm or to increase/decrease the Max Heap Size (-Xmx500m) setting.
Running JCA
To start the tool either click on the script or run it from a Windows cmd session. When tool starts you are presented with the following window. You use either File/Open or click on the This will display the Open screen. Browse to the directory where the javacore is stored and select it, then click Open. The tool will show a screen with a progress bar while it loads the javacore.
What it all means
Clicking on the javacore you just loaded in the Thread Dump List If the tool detected a deadlock then it will be displayed in the lower section of the Thread Dump List. Selecting the Compare Monitors option from Analysis Menu or clicking Will show the Deadlocked Threads.
Alternative way of finding Deadlocks in the Javacore.
A search for LKDEADLOCK in the Javacore file using grep or an editor such as vi would also identify the deadlocks 1LKDEADLOCK Deadlock detected !!! NULL --------------------- NULL 2LKDEADLOCKTHR Thread "WebContainer : 3" (0x00000001190A4700) 3LKDEADLOCKWTR is waiting for: 4LKDEADLOCKMON sys_mon_t:0x000000011B471160 infl_mon_t: 0x000000011B4711B0: 4LKDEADLOCKOBJ org/apache/log4j/DailyRollingFileAppender@07000000014CCA58/07000000014CCA70: 3LKDEADLOCKOWN which is owned by: 2LKDEADLOCKTHR Thread "WebContainer : 1" (0x00000001179C6500) 3LKDEADLOCKWTR which is waiting for: 4LKDEADLOCKMON sys_mon_t:0x00000001156FF760 infl_mon_t: 0x00000001156FF7B0: 4LKDEADLOCKOBJ org/apache/log4j/spi/RootLogger@0700000001C84A08/0700000001C84A20: 3LKDEADLOCKOWN which is owned by: 2LKDEADLOCKTHR Thread "WebContainer : 3" (0x00000001190A4700) NULL NULL
Steve Robinson has been working in IT for over 15 years and has provided solutions for many large-enterprise corporate companies across the world. Steve specialises in Java and Middleware consulting. Steve comes from both an administration and development background.
Before moving to JEE, Steve was an accomplished developer and consultant for both IBM Lotus Notes and Microsoft .NET Technologies.
Follow Steve as @stevencrobinson on twitter.
IBM WebSphere Application Server 8.0 Administration Guide
WebSphere Application Server 7.0 Administration Guide