[jboss-jira] [JBoss JIRA] Commented: (JBASM-3) Get a threaddump on hung servers

Aleksandar Kostadinov (JIRA) jira-events at lists.jboss.org
Thu Aug 21 08:48:39 EDT 2008


    [ https://jira.jboss.org/jira/browse/JBASM-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12426019#action_12426019 ] 

Aleksandar Kostadinov commented on JBASM-3:
-------------------------------------------

I looked at the things and would suggest the following solutions:
1. For the listThreadDump() to  work, server manager has to RMI connect to the server and call the method. It currently uses shutdown.jar for the job. So I'm going to change:
1.1. shutdown.jar to *not* be used
1.2. connect to the JBoss server
1.3. call the shutdown() method of jboss.system:type=Server
1.4. wait for server to shutdown (return if successful)
1.5. try calling listThreadDump() and output to server log or stdout (ignoring exceptions)
1.6. destroy process

positives:
* higher chance to be able to call the method successfully as server connection is not created after unknown number of services are already undeployed

negatives:
* dumps come in html markup (I tried EAP 4.3 CP02)
* additional dependencies to server manager (jars)

2. for kill-3
jboss-native needs a pre-compiled native library to  work on any platform. So I see it as an overkill for us. Instead I can change server start method to use specially crafted bash or/and perl script if the executable is found in PATH. Then doing destroy on the spawned process will cause kill -3 to the server process if it still exists followed by a kill -9.
We can't send ctrl+c to a terminal so on windows one would be stuck installing cygwin or perl for the feature to work. As well every platform I've looked at can have perl and/or bash installed.

> Get a threaddump on hung servers
> --------------------------------
>
>                 Key: JBASM-3
>                 URL: https://jira.jboss.org/jira/browse/JBASM-3
>             Project: JBoss AS Server Manager
>          Issue Type: Feature Request
>            Reporter: Dimitris Andreadis
>            Assignee: Shelly McGowan
>
> At times where the timeout for shutting down a server has passed, and we try to kill it, I think it would be a good idea to first send a signal to the server JVM to produce a threaddump so we capture that in the logs and see what happens in there.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list