I have a problem with eclipse that says the ports are already in use (80, 8009), When I change the ports I receive an error: Tomcat v6 at localhost failed to start.
When I debug Tomcat I receive this error:
11-Mar-2011 21:11:40 org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.6.0_21\bin;.;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files/Java/jre6/bin/client;C:/Program Files/Java/jre6/bin;C:/Program Files/Java/jre6/lib/i386;C:\Program Files\Java\jdk1.5.0_09\bin;C:\Program Files\QuickTime\QTSystem\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\apache-ant-1.8.1\bin;C:\Program Files\Subversion\bin;C:\Program Files\Java\jdk1.6.0_21\bin;C:\Users\Rajin\Desktop\eclipse-jee-helios-SR1-win32\eclipse;
11-Mar-2011 21:11:41 org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:EducationGamesApp' did not find a matching property.
11-Mar-2011 21:11:41 org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
11-Mar-2011 21:11:41 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 635 ms
11-Mar-2011 21:11:41 org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
11-Mar-2011 21:11:41 org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.29
11-Mar-2011 21:11:41 org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
11-Mar-2011 21:11:41 org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8008
11-Mar-2011 21:11:41 org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/29 config=null
11-Mar-2011 21:11:41 org.apache.catalina.startup.Catalina start
INFO: Server startup in 390 ms
11-Mar-2011 21:11:41 org.apache.catalina.core.StandardServer await
SEVERE: StandardServer.await: create[8005]:
java.net.BindException: Address already in use: JVM_Bind
at java.net.PlainSocketImpl.socketBind(Native Method)
at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:365)
at java.net.ServerSocket.bind(ServerSocket.java:319)
at java.net.ServerSocket.<init>(ServerSocket.java:185)
at org.apache.catalina.core.StandardServer.await(StandardServer.java:373)
at org.apache.catalina.startup.Catalina.await(Catalina.java:662)
at org.apache.catalina.startup.Catalina.start(Catalina.java:614)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)
Thanks
Most of the time, this means that Tomcat is already running in the background and Eclipse is trying to open it again on the same ports. This is obviously not possible, as the ports will be in use. The issue typically arises from either the Eclipse or Tomcat process crash or being stuck.
This error indicates that the server could not find the desired resource. This resource can be any file such as JSP, HTML, or image resource. Usually, the resource is present, but it is referenced incorrectly. In most cases, you can fix this by correcting the URL.
Out Of Memory Errors, or OOMEs, are one of the most common problems faced by Apache Tomcat users. Generally, these errors occur during development, but can even occur on production servers that are experiencing an unusually high spike of traffic.
For configuring the tomcat server in eclipse IDE, click on servers tab at the bottom side of the IDE -> right click on blank area -> New -> Servers -> choose tomcat then its version -> next -> click on Browse button -> select the apache tomcat root folder previous to bin -> next -> addAll -> Finish.
By default, Tomcat is using two ports: one for HTTP connector and one as "Server" port. If you open tomcat/conf/server.xml
, you will see these ports defined:
<?xml version='1.0' encoding='utf-8'?>
<Server port="8005" shutdown="SHUTDOWN">
...
<Service name="Catalina">
<Connector port="8080" protocol="HTTP/1.1" ...
...
<Connector port="8009" protocol="AJP/1.3" ...
</Service>
</Server>
As you can see, port 8009 is used for AJP connector and 8080 for HTTP connector.
You need to ensure none of these three ports are being used by your system (another Tomcat or just another application) and if they are, you need to change these values to something else.
download TCP view sw from the following link and unzip it. http://technet.microsoft.com/en-us/sysinternals/bb897437.aspx. see in the localport column is there any process worked in 8080 port . right click and end the process. then try to start the TomCat server. its really worked for me..
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With