aspose file tools*
The moose likes Tomcat and the fly likes shutdown  tomcat on port 8005 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "shutdown  tomcat on port 8005" Watch "shutdown  tomcat on port 8005" New topic
Author

shutdown tomcat on port 8005

bulent yuce
Greenhorn

Joined: Jul 29, 2007
Posts: 4
Hello everybody.

Why tomcat use port 8005?It is writing in server.xml file under %CATALINA_HOME%/conf.
... <Server port="8005" shutdown="SHUTDOWN"> ...
Is it for shutdown tomcat process?

I am starting tomcat with startup.bat in command line.
When i want to shutdown it in a new command line with shutdown.bat i took the following error:
"The process cannot access the file because it is being used by another process."

I can only shutdown tomcat process by closing the command line window that opened after i run startup.bat

Can anybody explain me the logic in shutdown?

Thanks
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 13868
    
  10

Besides the normal port that Tomcat listens on for connections (which is port 8080 by default), it also listens for commands on a different port (8005). Programs like shutdown.bat for example send special commands to a running Tomcat instance via this port to tell it to shutdown.

The error you get when you run shutdown.bat is strange, that shouldn't happen...


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
bulent yuce
Greenhorn

Joined: Jul 29, 2007
Posts: 4
I take this error on Windows OS.
But when i tried to shutdown tomcat server via shutdown.sh command on linux, it stopped tomcat server.

So i couldn't understand the reason of that.

When i look inside shutdown.sh or catalina.sh there isn't any port number 8005.

So how can shutdown.sh command send stop request to the running process?
Do you have any idea about that?

Thanks.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: shutdown tomcat on port 8005
 
Similar Threads
Possible causes of Intermittent/unexpected Tomcat 5.5.25 shut-downs?
Shutdown command with Apache Tomcat and Eclipse 3.4.2
Waiting for Tomcat to shut down
shutdown command
Tomcat Server Running Status