Starting Tomcatv6.0 Server at localhost has encoutered a problem, Port 80 required by Tomcat v6.0 server at localhost already in use. the server may already 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)

Starting Tomcatv6.0 Server at localhost has encoutered a problem, Port 80 required by Tomcat v6.0 server at localhost already in use. the server may already 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)

While working with tomcat, you might come across this glitch. Here is how to get rid of it easily.

1. Go to server tab in your eclipse. If you cant see it you can have it through window->show view->servers
2. double click on the tomcat server and you will be directed to page for tomcat configuration.
3. On the page you will see list of ports that the current server is using.
4. Change the HTTP/1.1 from 80 – or whatever it is complaining to new one like 9181.
5. what… you’re done… :)

Happy TomCatting.

Adding Java Project to new Java web application on Eclipse

19 Comments
  1. raj

    thx alottttttttttt………it worked nicely ….:D

    1. gullele

      Thanks Raj

  2. venu

    I am using tomcat v6.0 server at locallhost has encountered a probleam

  3. venu

    I have another problem .when i am opening eclipse it is automatically closed some times

  4. marulez

    thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.thank you.

    1. gullele

      Glad that helped you!!

  5. Sameer

    Wow its working… thanks

  6. kesan

    heyy thnks a ton.:)).its wrkng..!!!

    1. gullele

      Thanks

  7. Siza

    Hi, I tried your concise instruction but got warning “WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property ‘source’ to ‘org.eclipse.jst.jee.server:MyFirstWebApp’ did not find a matching property.” The web browser opened an 404 error page. Could you suggest a reason for this error?
    Many thanks for your help
    SZ

    1. gullele

      Hello Siza, you don’t have to worry about the warning in this case. That stuff is included by Eclipse and when tomcat encounter it, it just doesn’t know what to do with it.
      For the 404 error, there could be a lot of things that makes it like that
      1. Check what you have on you web.xml vs what you put on your url. If it is a JSF app, by default the url would be accessed from /faces/* that is if you have index.xhtml – then you would access it as http://localhost:%5Bport%5D/MyFirstWebApp/faces/index.xhtml..
      2. When you change the port, you should also change the previous port as well. If you were accessing the app using http://localhost:8080, then after changing the port to say 8083, then you should access it as localhost:8083..
      Also make sure the case sensitivity nature of file names ..
      Good luck

  8. keerthana

    Hey thanks a lot !!!! was breaking ma heads ….Thank you so much :) !!!

  9. computing2012

    hi
    I have a same problem but your solution didn’t work with me :(
    I used Tomcat 5

    1. gullele

      Hi there computingstudent2012
      Basically the error is coming out because other instance of tomcat is running. So in principle you can do two things.
      1. You can kill the other instance or
      2. You can change the port so that the other instance can listen to port 80 and yours current one would listen to whatever the new port is.

      As to kill the instance, basically the process, do:
      On linux: go to you command line and do ps -aux | grep tomcat
      this would give you the process id then issue kill processID or in worst case kill -9 processID
      On Windows: look for the process in the task manager or see if it is instantiated by some other service in services manager then kill/stop it

      As to changing, you can follow what is there on the blog.
      Let me know if the problem still persists

  10. mira

    4. Change the HTTP/1.1 from 80 – or whatever it is complaining to new one like 9181.

    how to change? i’m blurrrrrrr :(

    1. gullele

      Hey Mira,
      if you follow starting from the step 1, you would see it on the port edit box – it will list the default port, 8080, there. Then it will be a matter of changing that to a new one say 8082 and you can access your new site with localhost:8082.

  11. raghavendra

    thank you…

  12. felipe

    Sorry not very useful.

    The point is to run tomcat on port 80, not on another port.
    There is nothing running on port 80 on my computer, in fact after I get the error and while eclipse is open I can manually start tomcat on port 80, but no with eclipse.

    This solution is good if you can run your application on other ports, but in may case it must run on port 80.

    thanks any way. :-)

    1. gullele

      Sorry for the delayed answer. The main problem is regarding the port being taken by some other process. As you know, port is assigned per process basis under normal circumstances. In this case, port 80 is assigned. So you have two option to proceed. Either you kill the process using your OS tools or you would change the port and “fool” it for the time being.
      Thanks for stopping by commenting it.

Leave a Reply

Your email address will not be published. Required fields are marked *

*
*