• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Several ports required by Tomcat v5.5 Server at localhost are already in use

 
Ranch Hand
Posts: 191
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am getting below error on starting the tomcat server configured into Eclipse:

Several ports (8005, 8080, 8009) required by Tomcat v5.5 Server at localhost are already in use. The server may already be running in another process, or a system process may be using the port. To start this server you will need to stop the other process or change the port number(s).

Surprisingly, I can run tomcat server from outside the Eclipse environment on port 8080!

I tried following steps to resolve the issue, but none helps:

>> I run http://localhost:8080/ url in browser to test the server running on the port. But, page not found for 8005, 8080, and 8009 ports. It means these ports are not in use.

>> then i changed the port no. in server.xml file; still was getting the same error on starting the server.

>> then i restarted my machine. and still am getting the same error on running tomcat from eclipse.

>> i deleted and clean the current tomcat server configured into eclipse. but still no progress.

Please help me in resolving the issue.
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Good afternoon

I too have the same problem so I am hoping someone could detail what to look for to stop the "other process" which the server is suppose to be running.

Thanks Mary Nicholle
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

page not found for 8005, 8080, and 8009 ports. It means these ports are not in use.



Alas that is incorrect. Ports such as 8005 are used for control and "page not found" probably means the browser reached a HTTP server but the rest of the URL didn't point to a page the server could resolve. I say probably because if you have Microsoft Explorer "friendly HTTP error messages" turned on, it hard to say for sure what is wrong.

This kind of problem is why I hesitate to use an IDE for servlet development.

Bill
 
Mary Nicholle
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Bill

Thanks for the feedback

When I tried the localhost:8080 I got the Apache Tomcat home page which meant a successful setup of Tomcat.

Any other suggestions out there? Really need the help

Laters

 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. Looking for the default Tomcat startup was a good start so you know Tomcat is running.
2. The next thing to do is to find out if Tomcat recognizes your web application URL at all. The servlet API is very specific about the directory structure required and where various resources go. If there is an error in the web.xml deployment descriptor Tomcat won't treat your directory as an application, so check the logs from when Tomcat starts up for an error report.

Did you install Tomcat as a service or as an application?
How are you starting Tomcat?
Are we still talking about an Eclipse development environment?

Bill
 
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm getting the same error message when trying to start Tomcat 6 from Eclipse Galileo. However, if I start Tomcat with the startup command in <CATALINA_HOME>/bin it starts up normally with no complaints.

Is this an Eclipse or Tomcat (or both) issue?

-=b
 
vikas sharmaa
Ranch Hand
Posts: 191
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

William Brogden wrote:

Did you install Tomcat as a service or as an application?
How are you starting Tomcat?
Are we still talking about an Eclipse development environment?

Bill



i downloaded tomcat 5.5 from the internet and configure it into eclipse using create new web application wizard.

in my first post, i forgot to mention an important thing. i had formatted my C drive last week and downloaded & installed java 6 on my machine. when i ran the tomcat server first time, some process asked to access an internet site but i declined it without going into details. From then its continuously showing the "Several ports required by Tomcat v5.5 Server at localhost are already in use" error. I s it possible that some virus might not allowing me to run tomcat inside eclipse. But I have Mcaffe anti-virus installed. Please suggest.

Before formatting, I was able to run tomcat server inside eclipse.

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The error means the same what it says,
"you cannot run 2 instances of server on the same port".
in this case,it can be another project of yours that might have used tomcat previously and hasn't leaved it yet.

solution:
# if you are not sure if your port are currently being used ,
*either visit the link http://localhost:8080/ on your browser.If you get to the
server's homepage or see a typical 404 error,
your connetion is being used.
*or simply type the command netstat -a in terminal(linux) or command
prompt(windows)
it'll list down all the ports open/listening on your machine.

# once you get to know that the port you want to use is already in use,
*either shutdown the system(which will automatically free the ports) //bad option
*or change the ports 8001,8080,8009 from server.xml file
//u'll find it inside /conf directory of tomcat folder.
*or traverse to the place where you have installed your Apache Tomcat
go to /bin folder and execute the shutdown.bat file(windows) or shutdown.sh
file(Linux).it'll close your server and thus freeing the ports which were in use

open eclipse again and restart the server

regards,
Nalin_C
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic