Java: create Thread-Dump

17. April 2007

Before starting of expensive profiler sessions it helps sometimes to create a simple thread dump.

Run application in commandline mode.

Press [CTRL] [PAUSE]

a result:

$ ./start.sh
Starting oc4j.jar in /cygdrive/d/oc4j9.0.4.0/j2ee/home
07/03/20 16:33:28 log4j:WARN No appenders could be found for logger (de.calo.esb.context.ESBContextSupport).
07/03/20 16:33:28 log4j:WARN Please initialize the log4j system properly.
07/03/20 16:33:50 Oracle Application Server Containers for J2EE 10g (9.0.4.0.0) initialized
Full thread dump Java HotSpot(TM) Client VM (1.4.2_04-b05 mixed mode):
"DestroyJavaVM" prio=5 tid=0x00035e48 nid=0x7e8 waiting on condition [0..7fad8]
"TaskManager" prio=5 tid=0x02e84a50 nid=0xd58 waiting on condition [3f2f000..3f2fd90]
at java.lang.Thread.sleep(Native Method)
at com.evermind.util.TaskManager.run(TaskManager.java:236)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
"[Reconnector] vo.sdhreceiver_CCBdev_Importer" daemon prio=5 tid=0x02e1b878 nid=0x344 runnable [3eef000..3eefd90]
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.(Throwable.java:180)
at java.lang.Exception.(Exception.java:29)
at java.lang.RuntimeException.(RuntimeException.java:32)
at java.lang.NullPointerException.(NullPointerException.java:36)
at de.calo.esb.provider.jms.JmsQueueAdapter$Reconnector.run(JmsQueueAdapter.java:343)
"asyncDelivery0" daemon prio=5 tid=0x02e1be68 nid=0x6cc runnable [3eaf000..3eafd90]
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:129)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:183)
at java.io.BufferedInputStream.read(BufferedInputStream.java:201)
- locked  (a java.io.BufferedInputStream)
at java.io.DataInputStream.readInt(DataInputStream.java:443)
at com.ibm.mq.MQInternalCommunications.timedReadInt(MQInternalCommunications.java:3708)
at com.ibm.mq.MQInternalCommunications.receiveBytes(MQInternalCommunications.java:1168)
- locked  (a com.ibm.mq.MQInternalCommunications)
at com.ibm.mq.MQInternalCommunications.receive(MQInternalCommunications.java:1356)
- locked  (a com.ibm.mq.MQInternalCommunications)
at com.ibm.mq.MQSESSIONClient.lowLevelComms(MQSESSIONClient.java:2825)
- locked  (a java.lang.Integer)
at com.ibm.mq.MQSESSIONClient.MQGET(MQSESSIONClient.java:1869)
at com.ibm.mq.MQQueue.getMsg2Int(MQQueue.java:1126)
- locked  (a com.ibm.mq.MQSPIQueue)
at com.ibm.mq.MQQueue.getMsg2(MQQueue.java:986)
- locked  (a com.ibm.mq.MQSPIQueue)
at com.ibm.mq.jms.MQMessageConsumer.getMessageQ(MQMessageConsumer.java:1533)
at com.ibm.mq.jms.MQMessageConsumer.getMessage(MQMessageConsumer.java:4318)
at com.ibm.mq.jms.MQMessageConsumer.receiveAsyncQ(MQMessageConsumer.java:2506)
- locked  (a java.lang.Object)
- locked  (a com.ibm.mq.jms.MQQueueReceiver)
at com.ibm.mq.jms.MQMessageConsumer.receiveAsync(MQMessageConsumer.java:4262)
- locked  (a com.ibm.mq.jms.MQQueueReceiver)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:420)
at java.lang.Thread.run(Thread.java:534)
"[Reconnector] systemcontrol.subscriber_CCBdev_Importer" daemon prio=5 tid=0x02e81798 nid=0x6d4 waiting on
condition [3e6f000..3e6fd90]
at java.lang.Thread.sleep(Native Method)
at de.calo.esb.provider.jms.JmsTopicAdapter$Reconnector.run(JmsTopicAdapter.java:721)
"[JmsPollingThread] systemcontrol.subscriber_CCBdev_Importer" daemon prio=5 tid=0x02d9d008 nid=0x828 waiting on
condition [3e2f000..3e2fd90]
at java.lang.Thread.sleep(Native Method)
at de.calo.esb.provider.jms.PollingJmsTopicSubscriber$PollingThread.run(PollingJmsTopicSubscriber.java:160)
"[Reconnector] eventlogging.publisher_CCBdev_Importer" daemon prio=5 tid=0x030ed2b0 nid=0xce4 waiting on
condition [3def000..3defd90]
at java.lang.Thread.sleep(Native Method)
at de.calo.esb.provider.jms.JmsTopicAdapter$Reconnector.run(JmsTopicAdapter.java:721)
"[Reconnector] systemcontrol.publisher_CCBdev_Importer" daemon prio=5 tid=0x02ed6ce8 nid=0xdac waiting on
condition [3daf000..3dafd90]
at java.lang.Thread.sleep(Native Method)
at de.calo.esb.provider.jms.JmsTopicAdapter$Reconnector.run(JmsTopicAdapter.java:721)
"statusMgrConnection0" daemon prio=5 tid=0x02dbfa20 nid=0x994 runnable [3d6f000..3d6fd90]
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:129)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:183)
at java.io.BufferedInputStream.read(BufferedInputStream.java:201)
- locked  (a java.io.BufferedInputStream)
at java.io.DataInputStream.readInt(DataInputStream.java:443)
at com.ibm.mq.MQInternalCommunications.timedReadInt(MQInternalCommunications.java:3708)
at com.ibm.mq.MQInternalCommunications.receiveBytes(MQInternalCommunications.java:1168)
- locked  (a com.ibm.mq.MQInternalCommunications)
at com.ibm.mq.MQInternalCommunications.receive(MQInternalCommunications.java:1356)
- locked  (a com.ibm.mq.MQInternalCommunications)
at com.ibm.mq.MQSESSIONClient.lowLevelComms(MQSESSIONClient.java:2825)
- locked  (a java.lang.Integer)
at com.ibm.mq.MQSESSIONClient.MQGET(MQSESSIONClient.java:1632)
at com.ibm.mq.MQQueue.get(MQQueue.java:883)
- locked  (a com.ibm.mq.MQSPIQueue)
at com.ibm.mq.jms.MQPSStatusMgr$StatusMgrConnection.run(MQPSStatusMgr.java:1766)
at java.lang.Thread.run(Thread.java:534)
"PoolScavenger0" daemon prio=5 tid=0x02dcfde0 nid=0xf1c in Object.wait() [3d2f000..3d2fd90]
at java.lang.Object.wait(Native Method)
- waiting on  (a java.lang.Object)
at java.lang.Object.wait(Object.java:429)
at com.ibm.mq.PoolScavenger.run(PoolScavenger.java:152)
- locked  (a java.lang.Object)
- locked  (a com.ibm.mq.PoolScavenger)
at java.lang.Thread.run(Thread.java:534)
"eventlogging.publisher.queue" prio=5 tid=0x02dd5e10 nid=0xc60 runnable [3cef000..3cefd90]
at java.lang.Object.wait(Native Method)
- waiting on  (a de.calo.esb.queue.LinkedListQueueProcessor)
at de.calo.esb.queue.LinkedListQueueProcessor.run(LinkedListQueueProcessor.java:158)
- locked  (a de.calo.esb.queue.LinkedListQueueProcessor)
at java.lang.Thread.run(Thread.java:534)
"HttpConnectionListener [0.0.0.0/0.0.0.0:8888]" prio=5 tid=0x03159dd0 nid=0x464 runnable [34af000..34afd90]
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:353)
- locked  (a java.net.PlainSocketImpl)
at java.net.ServerSocket.implAccept(ServerSocket.java:448)
at java.net.ServerSocket.accept(ServerSocket.java:419)
at com.evermind.server.http.HttpConnectionListener.run(HttpConnectionListener.java:241)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
"RMIServer [/0.0.0.0:23791] count:1" prio=5 tid=0x030ceb88 nid=0xbbc runnable [346f000..346fd90]
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:353)
- locked  (a java.net.PlainSocketImpl)
at java.net.ServerSocket.implAccept(ServerSocket.java:448)
at java.net.ServerSocket.accept(ServerSocket.java:419)
at com.evermind.server.rmi.RMIServer.run(RMIServer.java:470)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
"JMSServer[CnC-SDH02:9127]" prio=5 tid=0x030d2c38 nid=0xd00 runnable [342f000..342fd90]
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:353)
- locked  (a java.net.PlainSocketImpl)
at java.net.ServerSocket.implAccept(ServerSocket.java:448)
at java.net.ServerSocket.accept(ServerSocket.java:419)
at com.evermind.server.jms.JMSServer.run(JMSServer.java:515)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
"Signal Dispatcher" daemon prio=10 tid=0x0003da38 nid=0xae8 runnable [0..0]
"Finalizer" daemon prio=9 tid=0x009c0968 nid=0xf40 in Object.wait() [2c5f000..2c5fd90]
at java.lang.Object.wait(Native Method)
- waiting on  (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:111)
- locked  (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:127)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:159)
"Reference Handler" daemon prio=10 tid=0x009bf530 nid=0xffc in Object.wait() [2c1f000..2c1fd90]
at java.lang.Object.wait(Native Method)
- waiting on  (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:429)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:115)
- locked  (a java.lang.ref.Reference$Lock)
"VM Thread" prio=5 tid=0x009fb6f8 nid=0xff0 runnable
"VM Periodic Task Thread" prio=10 tid=0x00a15700 nid=0xcf0 waiting on condition
"Suspend Checker Thread" prio=10 tid=0x0003d0e8 nid=0xb24 runnable

Often this helps to identify endless loops, bottle necks.

Remote desktop: keys

17. April 2007

important key combination with remote desktop:

[CTRL]+[ALT]+[BREAK]

- activate full screen

[CTRL]+[ALT]+[END]

- launch task manager dialog