Ok, will do.

Thanks, Chuck.

 

-----Original Message-----
From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] 
Sent: Friday, February 19, 2010 4:17 PM
To: Tomcat Users List
Subject: RE: DB connection error -Tomcat 6 config

> From: Propes, Barry L [mailto:barry.l.pro...@citi.com]
> Subject: DB connection error -Tomcat 6 config
> 
> I've left the content out of the server.xml file

I presume you meant "context" in the above statement.

> So I copied over my Oracle driver file in the jar file, ojdbc14_g.jar 
> to the TC 6 lib directory.

Good.

> There are jar files in the TC 4 commons/lib titled commons-dbcp- 
> 1.1.jar, commons-pool-1.1.jar, and jndi.jar.

You don't want those in Tomcat 6.

> context.xml file in conf

Big mistake: the conf/context.xml file is used *only* to hold attributes that 
you want common to all webapps.  You must not define anything specific to one 
webapp in there.  Put it back the way it was in the Tomcat download.

The <Context> element for your webapp should be in the webapp's 
META-INF/context.xml file.  (There are alternative locations, but that's 
usually the simplest.)

>  <Context path="/chngctrl" docBase="chngctrl"
>          debug="0" reloadable="true" crossContext="true"
> useNaming="true">

When you create the <Context> element in your webapp's META-INF/context.xml 
file, remove the path and docBase attributes; they're not allowed.  Remove the 
debug attribute, since that hasn't been used in many years.  The <Resource> 
element and its attributes belong in the webapp's <Context> element, not the 
global one.

>     <WatchedResource>WEB-INF/web.xml</WatchedResource>
>     <!-- Uncomment this to disable session persistence across Tomcat restarts 
> -->
>     <!--
>     <Manager pathname="" />
>     -->
>     <!-- Uncomment this to enable Comet connection tacking (provides events
>          on session expiration as well as webapp lifecycle) -->
>     <!--
>     <Valve className="org.apache.catalina.valves.CometConnectionManagerValve" 
> />
>     -->

Leave the above in conf/context.xml; do not include it in your webapp's 
<Context> element.

Fix the above, and try again.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY 
MATERIAL and is thus for use only by the intended recipient. If you received 
this in error, please contact the sender and delete the e-mail and its 
attachments from all computers.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to