Unable to generate thread dump


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Unable to generate thread dump
# 1  
Old 04-23-2020
Unable to generate thread dump

Hi,


We have been getting "Connection Time Out" issues for our Tomcat application.
One of the ways to track the problem is to run a thread dump on our applications. I used this command to generate the dump :

Code:
[root@app6 aigini]# /usr/lib/jvm/java-1.6.0-openjdk/bin/jstack -l 23688 /temp/app6thread.txt
Attaching to core /temp/app6thread.txt from executable 23688, please wait...
Error attaching to core file: Can't attach to the core file

[root@app6 aigini]# /usr/lib/jvm/java-1.6.0-openjdk/bin/jstack -l 23688 jstack.out
Attaching to core jstack.out from executable 23688, please wait...
Error attaching to core file: Can't attach to the core file
  [root@app6 aigini]#

As you can see, it throws error. Why is this, and how do I resolve this problem?


I also tried the command "jmap" below :

Code:
[root@app6 aigini]# /usr/local/jdk1.6.0_20/bin/jmap -heap:format=b 23688
Attaching to process ID 23688, please wait...
sun.jvm.hotspot.debugger.NoSuchSymbolException: Could not find symbol "gHotSpotVMTypeEntryTypeNameOffset" in any of the known library names (libjvm.so, libjvm_g.so, gamma_g)
        at sun.jvm.hotspot.HotSpotTypeDataBase.lookupInProcess(HotSpotTypeDataBase.java:388)
        at sun.jvm.hotspot.HotSpotTypeDataBase.getLongValueFromProcess(HotSpotTypeDataBase.java:369)
        at sun.jvm.hotspot.HotSpotTypeDataBase.readVMTypes(HotSpotTypeDataBase.java:102)
        at sun.jvm.hotspot.HotSpotTypeDataBase.<init>(HotSpotTypeDataBase.java:85)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.setupVM(BugSpotAgent.java:568)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.go(BugSpotAgent.java:494)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.attach(BugSpotAgent.java:332)
        at sun.jvm.hotspot.tools.Tool.start(Tool.java:163)
        at sun.jvm.hotspot.tools.HeapDumper.main(HeapDumper.java:77)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at sun.tools.jmap.JMap.runTool(JMap.java:179)
        at sun.tools.jmap.JMap.main(JMap.java:110)
Debugger attached successfully.
 sun.jvm.hotspot.tools.HeapDumper requires a java VM process/core!

Is the above the exact output? I don't see any dump in my working directory :


Code:
[root@app6 aigini]# ll
total 721660
-rw-r--r--. 1 tcpdump tcpdump   564392105 Feb 10 17:36 app6.pcap
-rw-r--r--. 1 tcpdump tcpdump      341630 Feb 10 17:42 app6web.pcap
-rw-r--r--. 1 root    root       67714741 Jul 10  2019 etms-web.war
-rwxr-xr-x. 1 apache  apache         9278 Dec 21  2018 httpd-ssl.conf
-rw-r--r--. 1 aigini  sysadmins     15419 Feb  7 13:42 output.txt
-rw-r--r--. 1 aigini  sysadmins  51302767 Dec 12 16:24 zakat-es.war
-rw-r--r--. 1 root    root           3872 Mar 13 17:21 zakatjosso.jsp
-rw-r--r--. 1 aigini  sysadmins  55177868 Dec 10 09:53 zakat.war
 [root@app6 aigini]#

This is the PID of the JAVA (Tomcat) application (It's running as user root) :



Code:
[root@app6 aigini]# ps -ef | grep tomcat | grep 6.0.32
root     23688     1  1 14:34 ?        00:01:27 /usr/lib/jvm/java-1.6.0-openjdk/bin/java -Djava.util.logging.config.file=/usr/local/apache-tomcat-6.0.32/conf/logging.properties -XX:PermSize=128M -XX:MaxPermSize=256M -Xms512m -Xmx1024m -Djava.security.auth.login.config=/usr/local/apache-tomcat-6.0.32/conf/jaas.conf -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Djava.endorsed.dirs=/usr/local/apache-tomcat-6.0.32/endorsed -classpath /usr/local/apache-tomcat-6.0.32/bin/bootstrap.jar -Dcatalina.base=/usr/local/apache-tomcat-6.0.32 -Dcatalina.home=/usr/local/apache-tomcat-6.0.32 -Djava.io.tmpdir=/usr/local/apache-tomcat-6.0.32/temp org.apache.catalina.startup.Bootstrap start


Last edited by anaigini45; 04-23-2020 at 06:20 AM..
# 2  
Old 04-23-2020
Collect Core Dumps
Shows how to locate core files. It looks to me like you do not have any existing core dumps -- I was not sure of your platform, looks like Solaris.
The article has a branchpoint set of links to platform specific information.

Plus I do not think version 6 of java is supported any longer. So getting Oracle help may not exist.

If anyone else knows more, please correct me.

You do know that sending the SIGSEGV signal to a given process (as root) will force a dump. Not a good idea in a production environment.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Unable to generate Ctrl M at end of rec

Hello, I was wondering if someone can assist me. I have a file that I download from a mainframe to a RedHat Linux 5.5 server, the file is delimited by control underscore characters and the record is terminated by a control M (carriage return). The problem I am having is with the control M... (3 Replies)
Discussion started by: app1mvf
3 Replies

2. Linux

Thread specific data from linux core dump

How do i get pointer to thread's local storage or thread specific data while analyzing core dump for linux ? i use pthread_setspecific to store some data in the pthread's local stoare. my multi threaded program on linux crashed, and i want to see what is stored in current running thread's... (2 Replies)
Discussion started by: vishwasungal
2 Replies

3. Shell Programming and Scripting

Thread Dump

I used take thread dump when our application gets out of memory issue. can any one help on check thread dump result. where it will save tool to read thread dump.:wall: date; kill -3 process_id; sleep 300; kill -3 process_id; sleep 300; kill -3 process_id;date (5 Replies)
Discussion started by: ram5019
5 Replies

4. Solaris

Thread Dump not working

Hello, I'm running a kill -QUIT on few process IDs (OS: Solaris) but the Thread Dump is empty. Can you please help me get it back on? Since I'm quite new to this, I'm not aware of the checks. Please let me know for the info required to debug this issue. Thanks! (3 Replies)
Discussion started by: DevendraG
3 Replies

5. Shell Programming and Scripting

Cannot generate core dump file

Segmentation fault(core dumped) but I cant find core file any where. how to make it out? I try the command:ulimit -c unlimited, I even added it to the .bashrc file.And I removed ulimit setting in /etc/init.d/function. And there's no ulimit setting in /etc/profile. And I tried sudo find /... (8 Replies)
Discussion started by: vistastar
8 Replies

6. Shell Programming and Scripting

Unable to catch the output after core dump and bus error

I have a weird situation in which the binary dumps core and gives bus error. But before dumping the core and throwing the buss error, it gives some output. unfortunately I can't grep the output before core dump db2bfd -b test.bnd maxSect 15 Bus Error (core dumped) But if I do ... (4 Replies)
Discussion started by: rakeshou
4 Replies

7. Forum Support Area for Unregistered Users & Account Problems

unable to post thread

Hello, I'd like to post a aix thread but I'm unable to. Please let me know why this is happening. Thanks.... (1 Reply)
Discussion started by: sullivjp
1 Replies

8. Programming

Thread prog (core dump)

Could any one please suggest me how to solve this...... when I compiled the program and tried to execute it as follows, it works fine under different inputs like: ./main -r 300 -w 3 -s 100 ./main -r 600 -w 3 -s 1000 ./main -r 10 -w 3 -s 100 But it fails when I tired to give the input as... (1 Reply)
Discussion started by: kumars
1 Replies

9. SCO

Unable to dump due to limited space?

After rebuilding the RAIDs on the SCO Unix, the following dialog appears when rebooting the machine. Fssat: /dev/boot mounted Mounted /stand filesystem Fsstat: /dev/usr1 okay Mounted /usr1 filesystem (continues usr2, usr3, Fsstat: /dev/usr4 okay Panic: HTFS: Bad directory ino... (2 Replies)
Discussion started by: Mac Tire
2 Replies

10. Post Here to Contact Site Administrators and Moderators

Unable to open thread

I am unable to open the mimesender thread. I get the following message when clicking on https://www.unix.com/showthread.php?p=33233#post33233 : (2 Replies)
Discussion started by: dangral
2 Replies
Login or Register to Ask a Question