java.lang.IllegalArgumentException:文档库不存在或不是可读目录

时间:2014-07-21 05:02:29

标签: java tomcat

我在 Tomcat7 的生产服务器中部署了服务器,并使用tomcat在映射域中进行了以下更改

<Host name="www.abc.in" appBase="webapps/3c"
unpackWARs="true" autoDeploy="true"
xmlValidation="false" xmlNamespaceAware="false">
                 <Context path="/3c" docBase="."/>
        <Alias>abc.in</Alias>

但是当我尝试启动服务器时,我最终会遇到异常

  

SEVERE:启动静态资源时出错   java.lang.IllegalArgumentException:文档库   /home/software/apache-tomcat-7.0.54/webapps/3c/。不存在或是   不是一个可读的目录           at org.apache.naming.resources.FileDirContext.setDocBase(FileDirContext.java:136)           at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:5089)           at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5269)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1559)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1549)           在java.util.concurrent.FutureTask.run(FutureTask.java:262)           在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)

     

2014年7月21日上午12:53:27 org.apache.catalina.core.ContainerBase   startInternal SEVERE:启动时子容器失败   java.util.concurrent.ExecutionException:   org.apache.catalina.LifecycleException:无法启动组件   [StandardEngine [卡塔利娜] .StandardHost [www.hsmg.in] .StandardContext [/ 3C]]           at java.util.concurrent.FutureTask.report(FutureTask.java:122)           在java.util.concurrent.FutureTask.get(FutureTask.java:188)           在org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)           在org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:799)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1559)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1549)           在java.util.concurrent.FutureTask.run(FutureTask.java:262)           在java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)           at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:615)           at java.lang.Thread.run(Thread.java:745)引起:org.apache.catalina.LifecycleException:无法启动组件   [StandardEngine [卡塔利娜] .StandardHost [www.hsmg.in] .StandardContext [/ 3C]]           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)           ... 6更多引起:org.apache.catalina.LifecycleException:resourceStart()出错           at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5270)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           ......还有6个

     

2014年7月21日上午12:53:27 org.apache.catalina.core.ContainerBase   startInternal SEVERE:启动时子容器失败   java.util.concurrent.ExecutionException:   org.apache.catalina.LifecycleException:无法启动组件   [StandardEngine [卡塔利娜] .StandardHost [www.hsmg.in]]           at java.util.concurrent.FutureTask.report(FutureTask.java:122)           在java.util.concurrent.FutureTask.get(FutureTask.java:188)           在org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)           在org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           在org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           在org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:731)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           在org.apache.catalina.startup.Catalina.start(Catalina.java:689)           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)           at java.lang.reflect.Method.invoke(Method.java:606)           在org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:321)           在org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455)引起   by:org.apache.catalina.LifecycleException:无法启动组件   [StandardEngine [卡塔利娜] .StandardHost [www.hsmg.in]]           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1559)           在org.apache.catalina.core.ContainerBase $ StartChild.call(ContainerBase.java:1549)           在java.util.concurrent.FutureTask.run(FutureTask.java:262)           在java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)           at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:615)           at java.lang.Thread.run(Thread.java:745)引起:org.apache.catalina.LifecycleException:子容器失败   在开始期间           在org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)           在org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:799)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           ......还有6个

     

2014年7月21日上午12:53:27 org.apache.catalina.startup.Catalina开始   严重:所需的服务器组件无法启动,因此Tomcat是   无法开始。 org.apache.catalina.LifecycleException:失败   启动组件[StandardServer [8005]]           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)           在org.apache.catalina.startup.Catalina.start(Catalina.java:689)           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)           at java.lang.reflect.Method.invoke(Method.java:606)           在org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:321)           在org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455)引起   by:org.apache.catalina.LifecycleException:无法启动组件   [StandardService [卡塔利娜]]           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)           在org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:731)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           ... 7更多引起:org.apache.catalina.LifecycleException:无法启动组件[StandardEngine [Catalina]]           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)           在org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           ... 9更多引起:org.apache.catalina.LifecycleException:子容器在启动期间失败           在org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)           在org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)           在org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)           ......还有11个

我尝试了以下

<Context path="/3c" docBase=" "/>
<Context path="/3c" docBase="webapps/3c"/>

但同样的例外

0 个答案:

没有答案