-
1. Re: Shutdown of JBoss AS 5.1 sometimes hangs
peterj Jun 6, 2011 11:51 AM (in response to baradon)First, check the log to make sure that it received the shutdown signal. Second, when the shutdown appears to "hang", take a JVM thread dump. Usually the stack trace for one of the threads will give a clue as to what is causing the holdup. The JVM will not exit until all threads are teminated, so one of the htreads still running is the culprit.
-
2. Re: Shutdown of JBoss AS 5.1 sometimes hangs
baradon Jun 7, 2011 3:40 AM (in response to peterj)Hi Peter,
well, I can do this in the lab, but I fear, it will not be possible to ask our customer to do such things on-site. Nevertheless, I will try to investigate it further. (And: Yes, the shutdown signal was received in all of those events.)
But the main question remains: Is there a way to tell the JVM to terminate completely, killing all of it's threads if they do not close properly?
Heiner
-
3. Re: Shutdown of JBoss AS 5.1 sometimes hangs
peterj Jun 7, 2011 10:06 AM (in response to baradon)But the main question remains: Is there a way to tell the JVM to terminate completely, killing all of it's threads if they do not close properly?
Yes, but you found it already: kill -9
I recommend you still run shutdown first and only use kill -9 if the shutdown doesn't happen. By doing this at least the threads that are not hung will have a chance to terminate.
-
4. Re: Shutdown of JBoss AS 5.1 sometimes hangs
baradon Jun 7, 2011 4:00 PM (in response to peterj)Okay, if this is the only way ...
We extended the init script. It first runs a normal shutdown and waits some time. If it detects a hanging server afterwards, it writes a thread dump to a file and goes for the heavy artillery .
All the best,
Heiner