tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ohaya <>
Subject Re: Newbie - JDBC problem "Name is not bound in this context"
Date Mon, 09 Aug 2004 13:29:51 GMT

Answers/comments below, interspersed...


d_l wrote:
> Can you clarify what version of Tomcat you are using?


I'm running Tomcat 5.0.27...

> It seems that there is a configuration change .. from Tomcat4 to Tomcat5 ..
> the context goes in to \conf\Catalina\localhost\<webappname>.xml .. for each
> webapp.
> Here is a reference I found in my own digging around ..
> _______________________________________________
> which states ..
> Please note that for tomcat 5.x, unlike tomcat 4.x, it is NOT recommended to place
> <Context> elements directly in the server.xml file. Instead, put them in the META-
> INF/context.xml directory of your WAR file or the conf directory as described above.
> _______________________________________________
> BUT .. in my Tomcat 5.0.27 ..  I only see three <webappname>.xml files in above
> location ..
> admin.xml
> balancer.xml
> manager.xml
> no other <webappname>.xml files (context.xml files) show up such as
> jsp-examples.xml
> servlets-examples.xml
> I don't understand why you have jsp-examples.xml and I don't see that file (only the
> three above).

No, I seem to have a .XML for each webapp.  I didn't create them, they
were just there.  Here's a 'dir' (I did create the 'new.xml' is for a
new test webapp that I'm working with):

 Volume in drive E is DATA
 Volume Serial Number is CE83-0200

 Directory of E:\Tomcat\jakarta-tomcat-5.0.27\conf\Catalina\localhost

08/05/2004  11:41p      <DIR>          .
08/05/2004  11:41p      <DIR>          ..
08/07/2004  01:09p                 370 admin.xml
08/07/2004  01:09p                 160 balancer.xml
08/07/2004  01:09p                 339 manager.xml
08/07/2004  01:09p                 176 webdav.xml
08/07/2004  01:09p                 566 servlets-examples.xml
08/07/2004  08:53p                 634 jsp-examples.xml
08/07/2004  01:09p                 186 tomcat-docs.xml
08/08/2004  12:35a                 239 ROOT.xml
08/08/2004  07:00p                 243 new.xml
               9 File(s)          2,913 bytes
               2 Dir(s)  22,732,374,016 bytes free

> " so I added just the ResourceLink to jsp-examples.xml,
> bounced Tomcat, and VOILA!!!  It worked!! "
> Where is the default context information when there is no <webappname>.xml?
> There is no context entry in server.xml.
> ...
> And I confirm that there is no webapps\examples\in my configuration ..
> replaced, it seems, by the two separate webapps above.
> ...
> I'm still puzzled.

On my system, it looks like there IS a <webappname>.xml, for each
webapp, and in each case, the <Context> is in these .XML files.

Thanks re. the 'examples' question.  That was causing me to wonder if
there was something wrong with my installation.

As to your implied question above of "why do I have all the .XML files,
whereas you only have 3?", is it possible that whoever built the Tomcat
installation created it that way?

FYI, I did my Tomcat installation from the Tomcat binaries for 5.0.27
(in a .zip file) that I found at, but I didn't
look closely at what was where after I unzipped the distribution, so it
may be that the .XML files were already in the distribution.  So I don't
know if they were there immediately after the unzip.  All I know is that
they're there now, and I didn't create them.

It does seem that you have to manually create these .XML files, as with
the new.xml, which I had to create manually, because when I started
Tomcat up without the new.xml file, I saw some errors on startup.


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

View raw message