myeclipse启动tomcat失败的解决办法 Failed to initialize connector [Connector[AJP/1.3-8009]]

之前装上了 myeclipse10  在使用过程中出现了一些问题。

1、打开myeclipse之后 无法启动tomcat服务

提示信息如下: 

2013-9-14 10:01:08 org.apache.catalina.core.AprLifecycleListener init
信息: Loaded APR based Apache Tomcat Native library 1.1.22.
2013-9-14 10:01:08 org.apache.catalina.core.AprLifecycleListener init
信息: APR capabilities: IPv6 [false], sendfile [true], accept filters [false], random [true].
2013-9-14 10:01:10 org.apache.coyote.AbstractProtocol init
信息: Initializing ProtocolHandler ["http-apr-8080"]
2013-9-14 10:01:10 org.apache.coyote.AbstractProtocol init
严重: Failed to initialize end point associated with ProtocolHandler ["http-apr-8080"]
java.lang.Exception: Socket bind failed: [730048] ?????????×???(Э?é/???????/???)????í??
 at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:401)
 at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:553)
 at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:369)
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:937)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:573)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:598)
 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.load(Bootstrap.java:281)
 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:449)
2013-9-14 10:01:10 org.apache.catalina.core.StandardService initInternal
严重: Failed to initialize connector [Connector[HTTP/1.1-8080]]
org.apache.catalina.LifecycleException: Failed to initialize component [Connector[HTTP/1.1-8080]]
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:106)
 at org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:573)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:598)
 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.load(Bootstrap.java:281)
 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:449)
Caused by: org.apache.catalina.LifecycleException: Protocol handler initialization failed
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:939)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 ... 12 more
Caused by: java.lang.Exception: Socket bind failed: [730048] ?????????×???(Э?é/???????/???)????í??
 at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:401)
 at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:553)
 at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:369)
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:937)
 ... 13 more
2013-9-14 10:01:10 org.apache.coyote.AbstractProtocol init
信息: Initializing ProtocolHandler ["ajp-apr-8009"]
2013-9-14 10:01:10 org.apache.coyote.AbstractProtocol init
严重: Failed to initialize end point associated with ProtocolHandler ["ajp-apr-8009"]
java.lang.Exception: Socket bind failed: [730048] ?????????×???(Э?é/???????/???)????í??
 at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:401)
 at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:553)
 at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:369)
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:937)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:573)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:598)
 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.load(Bootstrap.java:281)
 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:449)
2013-9-14 10:01:10 org.apache.catalina.core.StandardService initInternal
严重: Failed to initialize connector [Connector[AJP/1.3-8009]]
org.apache.catalina.LifecycleException: Failed to initialize component [Connector[AJP/1.3-8009]]
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:106)
 at org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:573)
 at org.apache.catalina.startup.Catalina.load(Catalina.java:598)
 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.load(Bootstrap.java:281)
 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:449)
Caused by: org.apache.catalina.LifecycleException: Protocol handler initialization failed
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:939)
 at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102)
 ... 12 more
Caused by: java.lang.Exception: Socket bind failed: [730048] ?????????×???(Э?é/???????/???)????í??
 at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:401)
 at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:553)
 at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:369)
 at org.apache.catalina.connector.Connector.initInternal(Connector.java:937)
 ... 13 more
2013-9-14 10:01:10 org.apache.catalina.startup.Catalina load
信息: Initialization processed in 2063 ms
2013-9-14 10:01:10 org.apache.catalina.core.StandardService startInternal
信息: Starting service Catalina
2013-9-14 10:01:10 org.apache.catalina.core.StandardEngine startInternal
信息: Starting Servlet Engine: Apache Tomcat/7.0.23
2013-9-14 10:01:10 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\company
2013-9-14 10:01:11 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\DB
2013-9-14 10:01:11 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\docs
2013-9-14 10:01:11 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\examples
2013-9-14 10:01:11 org.apache.catalina.core.ApplicationContext log
信息: ContextListener: contextInitialized()
2013-9-14 10:01:11 org.apache.catalina.core.ApplicationContext log
信息: SessionListener: contextInitialized()
2013-9-14 10:01:11 org.apache.catalina.core.ApplicationContext log
信息: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', 'org.apache.jasper.compiler.TldLocationsCache@3f3fbd')
2013-9-14 10:01:11 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\host-manager
2013-9-14 10:01:11 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\manager
2013-9-14 10:01:12 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\MyJspSite
2013-9-14 10:01:12 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\ROOT
2013-9-14 10:01:12 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\Test
2013-9-14 10:01:12 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\WebRoot
2013-9-14 10:01:12 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory D:\Tomcat7\webapps\WebTest
2013-9-14 10:01:13 org.apache.catalina.startup.Catalina start
信息: Server startup in 3101 ms
2013-9-14 10:01:13 org.apache.catalina.core.StandardServer await
严重: StandardServer.await: create[localhost:8005]: 
java.net.BindException: Address already in use: JVM_Bind
 at java.net.PlainSocketImpl.socketBind(Native Method)
 at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359)
 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:422)
 at org.apache.catalina.startup.Catalina.await(Catalina.java:706)
 at org.apache.catalina.startup.Catalina.start(Catalina.java:652)
 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:322)
 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:450)
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol pause
信息: Pausing ProtocolHandler ["http-apr-8080"]
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol pause
信息: Pausing ProtocolHandler ["ajp-apr-8009"]
2013-9-14 10:01:13 org.apache.catalina.core.StandardService stopInternal
信息: Stopping service Catalina
2013-9-14 10:01:13 org.apache.catalina.core.ApplicationContext log
信息: SessionListener: contextDestroyed()
2013-9-14 10:01:13 org.apache.catalina.core.ApplicationContext log
信息: ContextListener: contextDestroyed()
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol stop
信息: Stopping ProtocolHandler ["http-apr-8080"]
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol destroy
信息: Destroying ProtocolHandler ["http-apr-8080"]
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol stop
信息: Stopping ProtocolHandler ["ajp-apr-8009"]
2013-9-14 10:01:13 org.apache.coyote.AbstractProtocol destroy
信息: Destroying ProtocolHandler ["ajp-apr-8009"]

分析问题的原因:

端口号8080已经被占用。因为我开机时tomcat已经启动了,所以现在无法再eclipse中启动tomcat了。

解决办法:

ctrl+shift+esc 打开进程管理 在其中关闭tomcat的进程,重新启动myeclipse中的tomcat 。你会发现已经可以正常启动了。

展开阅读全文

没有更多推荐了,返回首页