We’re using Wildfly 11 with JDK 8 on Amazon Linux. How do I get a thread dump of our Wildfly process? We’re trying to troubleshoot why we’re seeing high CPU utilization for that process. We do NOT have jstack installed so I thought I could use “kill -3”, but it outputs nothing …
[myuser@mymachine ~]$ ps -elf | grep java 0 S jboss 1574 1 0 80 0 - 28276 - 07:02 ? 00:00:00 /bin/sh /usr/java/wildfly/bin/standalone.sh -c standalone.xml 0 S jboss 1617 1574 1 80 0 - 994904 - 07:02 ? 00:09:18 /usr/java/default/bin/java -D[Standalone] -server -Xms256m -Xmx2048m -XX:MetaspaceSize=256M -XX:MaxMetaspaceSize=512m -Djava.net.preferIPv4Stack=true -Dorg.jboss.boot.log.file=/usr/java/wildfly/standalone/log/server.log -Dlogging.configuration=file:/usr/java/wildfly/standalone/configuration/logging.properties -jar /usr/java/wildfly/jboss-modules.jar -mp /usr/java/wildfly/modules org.jboss.as.standalone -Djboss.home.dir=/usr/java/wildfly -Djboss.server.base.dir=/usr/java/wildfly/standalone -c standalone.xml 0 S 602 3777 3748 0 80 0 - 27619 - 15:24 pts/0 00:00:00 grep --color=auto java [myuser@mymachine ~]$ [myuser@mymachine ~]$ [myuser@mymachine ~]$ sudo kill -QUIT 1574 [myuser@mymachine ~]$
Any help is appreciated, –
Answer
The PID is incorrect. Try
sudo kill -QUIT 1617
That’s the java process that parent PID (1574) started
Attribution
Source : Link , Question Author : Dave , Answer Author : Ashok Kumar