2014-10-07 61 views
0

我使用eclipse中的tomcat服務器來執行我的項目。這些日子裏工作正常。但是自從3天以來,tomcat並不是從日食開始的。我在互聯網上查了很多很多的解決方案。即使在其他帖子中給出的與這個問題相關的堆棧溢出解決方案也沒有幫助我。控制檯消息是Tomcat有時不會在ubuntu14.04中通過eclipse啓動

Oct 07, 2014 11:08:06 AM 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: /usr/java/ packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib 
Oct 07, 2014 11:08:06 AM org.apache.tomcat.util.digester.SetPropertiesRule begin 
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:dims' did not find a matching property. 
Oct 07, 2014 11:08:06 AM org.apache.tomcat.util.digester.SetPropertiesRule begin 
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:DReST' did not find a matching property. 
Oct 07, 2014 11:08:06 AM org.apache.coyote.AbstractProtocol init 
INFO: Initializing ProtocolHandler ["http-bio-8181"] 
Oct 07, 2014 11:08:06 AM org.apache.coyote.AbstractProtocol init 
INFO: Initializing ProtocolHandler ["ajp-bio-8009"] 
Oct 07, 2014 11:08:06 AM org.apache.catalina.startup.Catalina load 
INFO: Initialization processed in 303 ms 
Oct 07, 2014 11:08:06 AM org.apache.catalina.core.StandardService startInternal 
INFO: Starting service Catalina 
Oct 07, 2014 11:08:06 AM org.apache.catalina.core.StandardEngine startInternal 
INFO: Starting Servlet Engine: Apache Tomcat/7.0.54 
Oct 07, 2014 11:08:07 AM org.apache.tiles.impl.BasicTilesContainer init 
INFO: Initializing Tiles2 container. . . 
Oct 07, 2014 11:08:07 AM org.apache.tiles.impl.BasicTilesContainer initializeDefinitionsFactory 
INFO: Tiles2 container initialization complete. 
Oct 07, 2014 11:08:07 AM org.apache.tiles.access.TilesAccess setContainer 
INFO: Publishing TilesContext for context: org.apache.catalina.core.ApplicationContextFacade 
Oct 07, 2014 11:08:07 AM com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 
INFO: Parsing configuration file [struts-default.xml] 
Oct 07, 2014 11:08:07 AM com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 
INFO: Parsing configuration file [struts-plugin.xml] 
Oct 07, 2014 11:08:07 AM com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 
INFO: Parsing configuration file [struts.xml] 
Oct 07, 2014 11:08:07 AM org.apache.struts2.config.BeanSelectionProvider info 
INFO: Loading global messages from ApplicationResources 
Servlet Context --call back method--contextInitialized() 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/StudentDao.properties 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/ 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/ 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/ 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/ 
/home/saipavan/apache-tomcat-7.0.54/wtpwebapps/dims/ 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deploying web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/manager 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deployment of web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/manager has finished in 75 ms 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deploying web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/ROOT 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deployment of web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/ROOT has finished in 67 ms 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deploying web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/host-manager 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deployment of web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/host-manager has finished in 70 ms 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deploying web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/examples 
Oct 07, 2014 11:08:09 AM org.apache.catalina.core.ApplicationContext log 
INFO: ContextListener: contextInitialized() 
Oct 07, 2014 11:08:09 AM org.apache.catalina.core.ApplicationContext log 
INFO: SessionListener: contextInitialized() 
Oct 07, 2014 11:08:09 AM org.apache.catalina.core.ApplicationContext log 
INFO: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', '[email protected]') 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deployment of web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/examples has finished in 142 ms 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deploying web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/docs 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.HostConfig deployDirectory 
INFO: Deployment of web application directory /home/saipavan/apache-tomcat-7.0.54/webapps/docs has finished in 68 ms 
Oct 07, 2014 11:08:09 AM org.apache.coyote.AbstractProtocol start 
INFO: Starting ProtocolHandler ["http-bio-8181"] 
Oct 07, 2014 11:08:09 AM org.apache.coyote.AbstractProtocol start 
INFO: Starting ProtocolHandler ["ajp-bio-8009"] 
Oct 07, 2014 11:08:09 AM org.apache.catalina.startup.Catalina start 
INFO: Server startup in 2670 ms 

我能夠通過終端啓動tomcat。但是當我嘗試在啓動後在瀏覽器中打開tomcat時,出現錯誤

Firefox can't establish a connection to the server at localhost:8181. 

可能是什麼問題?誰能幫我?謝謝。

回答

0

似乎localhost沒有解析爲IP地址。嘗試ping本地主機ping -c localhost或嘗試您的系統IP地址,而不是本地主機。

+0

$ ping localhost
'PING localhost(127.0.0.1)56(84)字節的數據。從本地主機
64字節(127.0.0.1):icmp_seq = 1個TTL = 64時間= 0.028毫秒從本地主機
64字節(127.0.0.1):icmp_seq = 2 TTL = 64時間= 0.032毫秒從本地主機
64字節(127.0.0.1):icmp_seq = 3 TTL = 64時間= 0.021毫秒從本地主機
64字節(127.0.0.1):icmp_seq = 4 TTL = 64時間= 0.013 ms'

$平-c本地主機
'ping:發送數據包的數量不好.' – Pawan 2014-10-07 06:00:32