Forums Register Login

New Context problem - Tomcat 4.1.12

+Pie Number of slices to send: Send
I've created a context for my webapp in server.xml so that I could set up a connection pool.
In doing so, Tomcat raises an exception on startup while trying to unpack the war, saying that the directory (into which it is trying to unpack) does not exist or is unreadable. If I create an empty directory there, it does start up, but of course, does not unpack.
Here's the top of the exception stack trace:

Here's root elem of the context from server.xml:

If I change the docbase to name the war (docBase="foobar.war"), the app runs, but does not unpack into a dir - this is not what I want.
It seems to be a catch-22. It won't start w/o an existing target directory to unpack into, and it won't unpack if the directory exists.
Obviously I've misunderstood something in the context declaration, but I'm stumped for the moment.
+Pie Number of slices to send: Send
in server.xml files for the Host node "unpackWARs"
property should be set to true for automatic expansion
+Pie Number of slices to send: Send
Thanks for the reply.
The unpackWARs element is set to "true".
The war does get unpacked when I don't have that context in server.xml ( of course, I need that there to set up my connection pool ).
As soon as I add the context, Tomcat startup fails with the above exception.
Maddening.
+Pie Number of slices to send: Send
What happens if you add that context after the WAR has been unpacked?
Bill
+Pie Number of slices to send: Send
The above problem in adding a new context can be easily solved if we use ant1.5.1 for the purpose of compiling,making war file etc.Also now there is particular order of declaration in WEB-INF folder of web.xml also as <servlet> etc .If u don't folow the order then it will the parser error.
We solved the above problem by using the docs provided at:
http://jakarta.apache.org/tomcat-4.1-doc/appdev/deployment and source organiztion,processes pages.There is a default build.xml is also provided and a sample project can be made with the help of this provided u r using tomcat-4.1.12.With various commands of ant as ant all
ant dist
u compile,make war file deployable in webapps.
Also there is an added facility in tomcat4.1.12.Tha manager facility which can accessed from main tomcat page but first setting the password in tomcat-users.xml in conf of tomcat as say
<user username="alok" password="alok" roles="standard,manager,admin"/>
and passing the usrname/pwd in the window opening while accessing the manager link from main page.
u can view all the deployed,running applications on tomcat.Reg manager docs of tomcat provided in tomcat itself can be referred.
I claim this furniture in the name of The Ottoman Empire! You can keep this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 1193 times.
Similar Threads
Tomcat: problem with server.xml context
Tomcat 4.0.2 unpacking wars
UnpackWAR
Configuration questions for Tomcat
Problem with context in server.xml
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 09:37:34.