tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: Documentation for Catalina Base
Date Tue, 31 Jul 2018 13:34:19 GMT
Hash: SHA256


On 7/31/18 4:24 AM, Stefan Mayr wrote:
> Hi,
> Am 30.07.2018 um 18:25 schrieb Christopher Schultz:
>> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256
>> Marek,
>> On 7/30/18 3:22 AM, Marek Czernek wrote:
>>> Hi there,
>>> recently, we noticed the lack of documentation for Catalina
>>> Base, and I wanted to find out more about it. Other than a
>>> strangely obscure txt file [1], I did not find the concept and
>>> usage of Catalina Base documented in the Tomcat docs.
>> Do you mean the CATALINA_BASE environment variable, which is
>> copied into a running JVM as the "catalina.base" system
>> property?
>>> My questions are:
>>> 1) Did I overlook it being documented somewhere?
>> Other than in RUNNING.txt (where it is thoroughly described), it
>> is documented in:
>> 1. bin/ and bin/catalina.bat 2. The "Directories and
>> Files" section of each Tomcat X documentation (e.g. 
>> 3. The "Introduction" section of each Tomcat X configuration
>> guide for the "context" container (e.g. 
>>> 2) If not, is there any reason for it not being documented?
>>> While I don't want to duplicate text, I do not consider a txt
>>> file somewhere a sufficient docs.
>> What, it needs to be in TeX, too?
>>> If the answer to both of my questions is no, we'll create a
>>> patch against the Tomcat docs.
>>> [1]
>> Patches are always welcome, but I believe it is currently 
>> properly-documented.
>> Is there something specific you were looking for and could not
>> find?
> That's the point to ask for some details I'm struggeling with
> 1. $CATALINA_BASE/bin/tomcat-juli.jar: when do I need to place this
> jar in this directory? It is only clear to have it in CATALINA_BASE
> for the documented switch to log4j. From reading I
> would say it is only necessary to place it in CATALINA_BASE when we
> want to use a different version. Is this assumption correct?

That file should generally be in CATALINA_HOME/bin and should match
the version of Tomcat is shipped with. If you want to use log4j for
logging, I would *always* place the replacement JULI implementation
into CATALINA_BASE/lib and leave the Tomcat "stock" installation alone.

> 2. $CATALINA_BASE/conf: What files have to be in this directory?

web.xml (though I have argued that this should inherit from CATALINA_HOM

There are other things that you might want to add, depending upon your

> If they are not present - are they loaded from CATALINA_HOME? 
> RUNNING.txt only mentions server.xml. But it looks like we need to 
> have at least a copy of web.xml in this directory too.
Yes, this is true:

> Reading we also should copy (or link) catalina.policy
> when running with a security manager.


> For other files the situation is not clear, e.g. 
>, context.xml
Both and context.xml will fall-back to
CATALINA_HOME if they don't exist in CATALINA_BASE.

You may also want to put a static-user file e.g. tomcat-users.xml into
your CATALINA_BASE/conf directory. All paths in server.xml are
relative to CATALINA_BASE, so if you e.g. configure a <Resource> like

    <Resource name="UserDatabase" auth="Container"
              description="User database that can be updated and saved"

              pathname="conf/tomcat-users.xml" />

Then conf/tomcat-users.xml will be found in CATALINA_BASE. Of course,
you can always use an absolute path and put it anywhere you want... it
doesn't have to be in that location, though many people will expect it
to be there if it's being used.

> ... Some stackoverflow answers to that question recommend to copy
> the whole conf directory from CATALINA_HOME to CATALINA_BASE. I'm
> not sure if this is a good idea if I don't need to change the 
> defaults. The documentation could be improved by listing the files
> that are mandatory in CATALINA_BASE


- -chris
Comment: GPGTools -
Comment: Using GnuPG with Thunderbird -


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

View raw message