I am having problems trying to get a simple servlet to run on Tomcat6.0 on WinXP I am seeing the following error
SEVERE: Error starting static Resources java.lang.IllegalArgumentException: Document base C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\webapps\MyFristApp does not exist or is not a readable directory at org.apache.naming.resources.FileDirContext.setDocBase(FileDirContext.java:141) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:3941) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4112) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014) at org.apache.catalina.core.StandardHost.start(StandardHost.java:719) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) at org.apache.catalina.core.StandardService.start(StandardService.java:448) at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) at org.apache.catalina.startup.Catalina.start(Catalina.java:552) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) 16-Feb-2007 22:48:59 org.apache.catalina.core.StandardContext start
java.lang.IllegalArgumentException: Document base C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\webapps\MyFristApp does not exist or is not a readable directory.
Thanks in advance for any help.
[ February 16, 2007: Message edited by: IdrisK ]
[ February 16, 2007: Message edited by: IdrisK ] [ February 16, 2007: Message edited by: Bear Bibeault ]
Bear Bibeault
Author and opinionated walrus
Marshal
Yes changed my setup to C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\webapps\MyFirstApp so that it is the same as my Context path in server.xml
java.lang.IllegalArgumentException: Document base C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\webapps\MyFristApp does not exist or is not a readable directory.
I am not sure where this path is coming from, I have checked the server.xml The web.xml is as follows.
<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
Any ideas as to where its picking this path up from? C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\webapps\MyFristApp [ February 16, 2007: Message edited by: Idris Pathan ]
Micky Danese
Greenhorn
Joined: Sep 22, 2011
Posts: 2
posted
0
Check your server.xml file (tomcathome/conf/server.xml)
is there a <context> element with a reference to the problem directory?
yes : remove it.
Santiago Carrillo
Greenhorn
Joined: Jan 27, 2012
Posts: 1
posted
0
In Eclipse: Just go to the server that you have configured , right click -> Add and Remove: and then remove all the not used projects or the ones that you have deleted before, the error should not come anymore !
Bear Bibeault
Author and opinionated walrus
Marshal