|Re: Cannot shut down Apache Tomcat 6.0 [message #683920 is a reply to message #683702]
||Tue, 14 June 2011 16:29
| Larry Isaacs
Registered: July 2009
On 6/14/2011 5:21 AM, Matei wrote:|
> I am using Eclipse Helios SR1 and Apache Tomcat 6.0.32.
> Tomcat starts just fine, but when I try to stop it / shut it down it
> creates a new console which terminates its execution quickly in which it
> doesn't display anything.
> Meanwhile Tomcat's console displays the shutdown procedure messages and
> when it is all done it just hangs, the process isn't killed.
> The last lines are usually:
> Jun 1, 2011 12:54:56 PM org.apache.coyote.http11.Http11AprProtocol destroy
> INFO: Stopping Coyote HTTP/1.1 on http-8080
> Jun 1, 2011 12:54:56 PM org.apache.coyote.ajp.AjpAprProtocol destroy
> INFO: Stopping Coyote AJP/1.3 on ajp-8009
> After these Tomcat should have shut down, but it just hangs.
> Can anybody please give a solution, or at least a suggestion? And why is
> the second console created ?
> Thank you!
The second console is to send a "shutdown" request to the shutdown port
of the Tomcat server. This allows Tomcat to perform an controlled
shutdown. However, it is a known behavior of Tomcat that it will wait
*forever* for all webapps to "clean up" before exiting.
Usually this situation occurs when a webapp starts a non-daemon thread
which it fails to terminate when shutdown. It can also occur if the
webapp uses RMI and fails to free all the remote objects at shutdown.
Typically you can see threads are the problem by running in debug mode
and checking the Debug window after shutdown to see what threads are
still running. You may need to pull down the Debug window's "View Menu"
(the one next to Minimize and Maximize icons) and select Java -> Show
System Threads to see the threads that are the cause of the problem.
Normally, after the specified shutdown period, a dialog should appear
asking if you want to terminate the Tomcat server. I don't know why
this would not appear for you.
Powered by FUDForum
. Page generated in 0.03385 seconds