将.war文件部署到linux上的tomcat服务器

时间:2015-09-14 20:00:09

标签: java linux deployment server tomcat7

代码和.war文件在localhost服务器(运行Windows)上工作得很好,但是当我们尝试在Linux服务器上部署和启动时,它失败了,我们收到了以下错误。

  

org.apache.catalina.deploy.NamingResources cleanUp警告:失败   检索容器的JNDI命名上下文   [StandardEngine [卡塔利娜] .StandardHost [本地主机] .StandardContext [/ SmartHomeReasoner]]   所以没有对该容器进行清理   javax.naming.NameNotFoundException:名称[comp / env]未绑定   这个背景。无法找到[comp]。           在org.apache.naming.NamingContext.lookup(NamingContext.java:819)           在org.apache.naming.NamingContext.lookup(NamingContext.java:167)           在org.apache.catalina.deploy.NamingResources.cleanUp(NamingResources.java:986)           在org.apache.catalina.deploy.NamingResources.stopInternal(NamingResources.java:968)           在org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)           在org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5676)           在org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:141)           在org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1256)           在org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:692)           at org.apache.catalina.manager.HTMLManagerServlet.doPost(HTMLManagerServlet.java:217)           在javax.servlet.http.HttpServlet.service(HttpServlet.java:646)           在javax.servlet.http.HttpServlet.service(HttpServlet.java:727)           在org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)           在org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)           在org.apache.catalina.filters.CsrfPreventionFilter.doFilter(CsrfPreventionFilter.java:213)           在org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)           在org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)           在org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108)           在org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)           在org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)           在org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)           在org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)           在org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:610)           在org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)           at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)           在org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)           在org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)           在org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)           在org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1041)           at org.apache.coyote.AbstractProtocol $ AbstractConnectionHandler.process(AbstractProtocol.java:607)           在org.apache.tomcat.util.net.JIoEndpoint $ SocketProcessor.run(JIoEndpoint.java:313)           在java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)           at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:615)           在java.lang.Thread.run(Thread.java:745)

1 个答案:

答案 0 :(得分:0)

答案可在以下链接中找到:

.War Works to deploy on Windows but fails to deploy on a Linux server (Tomcat 7)

谢谢你的关注。