commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dirk Verbeeck <>
Subject Re: DBCP: and shared tomcat instances
Date Wed, 31 Dec 2003 12:18:45 GMT
Normally putting the diver in the system classpath should work (at 
least with tomcat 4.1)
In our production environment we have the same setup. One shared 
tomcat install with a special startup script. This scipt sets the 
system classpath and other environment variables.

PS: you want to make sure you only have one copy of DBCP and the 
database drivers. Don't put then in WEB-INF/lib if you have then 

-- Dirk

Harbick, Andrew wrote:
> You can have multiple instances of Tomcat using the CATALINA_BASE environment variable:
> However, it doesn't seem that you can "overried" the common/lib directory as well.
> My problem is that I don't own $CATALINA_HOME, and $CATALINA_HOME/common/lib doesn't
contain my JDBC driver, and it would be a pain to get the owner to add it (they tend to try
to keep "global" installations virgin)
> This however means that I can't get DBCP to work because it always throws an exception
indicating that the JDBC driver couldn't be loaded.
> I've tried:
>    -Dorking with CLASSPATHs but I think that's pointless because of the Tomcat class
loading model:
>    -Adding the JDBC jar to WEB-INF/lib in my webapp *.war file (but that didn't work
and I saw information suggesting that it shouldn't)
>    -Trying to find a way to override common/lib, but I couldn't find anything that would
allow that.
> So I'm a bit stuck.  It seems like my only options are:
>   1.  Get the owner of $CATALINA_HOME to drop the JDBC driver in $CATALINA_HOME/common/lib
>   2.  Install my own "local" instance that I do have control over $CATALINA_HOME/common/lib
>   3.  Find some way to override the common/lib dir.
> ...or something else.
> Does anyone have insight into how to use a "shared instance" of Tomcat with DBCP?
> Thanks,
> Andy

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message