| Author |
Tomcat can't be stopped
|
Yuan Ye
Ranch Hand
Joined: Mar 05, 2003
Posts: 172
|
|
I am trying to learn using Tomcat. But I found whenever I try to stop Tomcat using shutdown.bat in Windows2000, I get the following result. Thus prevents me from restarting Tomcat. I have to restart my Windows every time to restart Tomcat. Does anyone know why that happens and how to solve it? Thank you very much. Using CATALINA_BASE: /usr/jakarta-tomcat-4.1.24 Using CATALINA_HOME: /usr/jakarta-tomcat-4.1.24 Using CATALINA_TMPDIR: /usr/jakarta-tomcat-4.1.24/temp Using JAVA_HOME: /usr/java/jdk1.3.1_01 Catalina.stop: java.net.ConnectException: Connection refused java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:320) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:133) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:120) at java.net.Socket.<init>(Socket.java:273) at java.net.Socket.<init>(Socket.java:100) at org.apache.catalina.startup.Catalina.stop(Catalina.java:579) at org.apache.catalina.startup.Catalina.execute(Catalina.java:402) at org.apache.catalina.startup.Catalina.process(Catalina.java:180) at java.lang.reflect.Method.invoke(Native Method) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
|
 |
William Brogden
Author and all-around good cowpoke
Rancher
Joined: Mar 22, 2000
Posts: 11863
|
|
Hmm - I get the same thing - thats surprising. Are you starting Tomcat as a service, that may have something to do with it. Bill
|
 |
Yuan Ye
Ranch Hand
Joined: Mar 05, 2003
Posts: 172
|
|
|
Yes, I also use Tomcat as the HTTP server. The whole thing is a standalone container. Anybody knows how to shutdonw Tomcat in this case? Thanks
|
 |
Yuan Ye
Ranch Hand
Joined: Mar 05, 2003
Posts: 172
|
|
I found one solution. It is really related to windows service. Since when I install the Tomcat I included the NT service. And now I am trying to shut down the whole service in "Adminstrative Tools" -> "Services". And this works. Now the question becomes if I install Tomcat without NT service I always has problem to start Tomcat. How to solve this? Thanks
|
 |
Mike Curwen
Ranch Hand
Joined: Feb 20, 2001
Posts: 3695
|
|
Either install the service and use the Services control panel to stop and start tomcat (the whole point of installing it as a service is to have a "hands off" approach to running and stopping the program). If you want to be able to start and stop tomcat from batch files, then install the service, but using the Services control panel, set the startup mode to "manual". This will ensure it won't start automatically with windows, and your batch files will work. Third, never mind the service and use batch files exclusively. finally, you can use the service, and create your own batch files, a single line for each.
|
 |
R Kap
Greenhorn
Joined: Oct 22, 2002
Posts: 2
|
|
|
You could go to the services and there change the startup type of Tomcat from automatic to Manual.Doing this you can start and stop the server through the start and stop commands.
|
 |
 |
|
|
subject: Tomcat can't be stopped
|
|
|