錯誤提示如下:
四月 25, 2015 11:56:45 上午 org.apache.coyote.AbstractProtocol destroy
信息: Destroying ProtocolHandler ["ajp-nio-8088"]
四月 25, 2015 11:56:45 上午 org.apache.coyote.AbstractProtocol destroy
嚴重: Failed to destroy end point associated with ProtocolHandler ["ajp-nio-8088"]
java.lang.NullPointerException
at org.apache.tomcat.util.net.NioEndpoint.releaseCaches(NioEndpoint.java:302)
at org.apache.tomcat.util.net.NioEndpoint.unbind(NioEndpoint.java:473)
at org.apache.tomcat.util.net.AbstractEndpoint.destroy(AbstractEndpoint.java:818)
at org.apache.coyote.AbstractProtocol.destroy(AbstractProtocol.java:532)
at org.apache.catalina.connector.Connector.destroyInternal(Connector.java:1023)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:588)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:859)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
at org.apache.catalina.startup.Catalina.start(Catalina.java:629)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:351)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:485)
上面8088是我把8009改過來的,另外我還試了8007,這就排出了端口的問題!
eclipse 有一個自帶的tomcat,你必須把他先禁止掉,之後選擇自己的tomcat,這樣應該可以了,如果還不行,我們可以繼續交流
上圖中,1,在windows---prefrences中搜索tomcat 2、eclipse自帶的tomcat 3、自己的tomcat
如果你需要部署 web到自己的tomcat上,需要先把eclipse自帶的tomcat給禁止掉
選中eclipse自帶的tomcat 點擊disable
接著再選中自己下載的tomcat選中enable