This section provides basic reference information about the tc Server
installation directories and the most important configuration files. The
section includes the following topics:
When you install the tc Server application server itself (as opposed to
the AMS-related components), the install script asks you for a main
installation directory; the install script then creates a sub-directory
under the inputted directory called tcServer-6.0 that
contains all tc Server-related files.
The tcServer-6.0 directory in turn contains the
following directories and files:
- tomcat-version, where version is the version of tc Server, such as tomcat-6.0.20.C : This is the basic Apache
Tomcat CATALINA_HOME directory; users of standard
Apache Tomcat will recognize its contents. The Tomcat binaries are
in the bin directory, the server configuration files
for the default Tomcat server instance are in the conf
directory, and so on.
Users who want to use the standard Apache
Tomcat server layout should use this directory as usual.
- tijars : This directory contains JAR files used
by tc Server that are different to standard Apache Tomcat.
- tcserver-instance.sh|bat : Scripts for creating
new tc Server instances when using the SpringSource directory layout,
rather than the standard Apache layout. See Differences between the SpringSource and ASF Layouts of tc Server for information about these two directory layouts.
When you create a new server instance using this script, the
script creates a sub-directory of the tcServer-6.0
directory with the same name as the new server instance; this new
directory is the CATALINA_BASE of the server instance.
The new directory contains the server-specific configuration files,
its own Web application deployment directory, log files, and so on.
- tcserver-ctl.sh|bat : Main tc Server control
scripts. The bin directories of individual tc Server
instances include their own versions of these scripts that in turn call
these main ones. You can also call the top-level scripts if you also
specify the name of the tc Server instance.
As already implied, after installing tc Server, you can chose to use
the following two directory layouts for your tc Server instance(s):
- SpringSource layout
- Standard Apache (ASF) layout
The SpringSource layout differs slightly from the Apache layout in that
SpringSource separates the runtime binaries from the configuration data.
For additional details about how the SpringSource layout
differs from standard Apache, see Differences between the SpringSource and ASF Layouts of tc Server.
Unless otherwise indicated, it is assumed that you are using the
SpringSource directory layout.
tc Server Variables
The
following two tc Server variables are used extensively in the documentation.
- CATALINA_HOME: Represents the root
directory of your tc Server installation. For both layouts
(SpringSource and ASF), the CATALINA_HOME variable
points to the same directory:
INSTALL_DIR/tcServer-6.0/tomcat-version,
where INSTALL_DIR refers to the directory in
which you installed tc Server, such as /home/tcserver,
and version is the version of tc Server, such
as 6.0.20.C.
The CATALINA_HOME directory always contains, for
example, a bin sub-directory that in turn contains the
tc Server binary files.
- CATALINA_BASE: Represents the root directory
of a particular tc Server instance. The CATALINA_BASE
directory always contains, for example, the conf
sub-directory that in turn contains the configuration files for the
particular tc Server instance.
In the ASF layout, CATALINA_BASE is the same as
CATALINA_HOME, namely INSTALL_DIR/tcServer-6.0/tomcat-version. In the SpringSource layout, however,
CATALINA_BASE is different and points to the directory
created by the tcserver-instance.sh script.
tc Server Directory Structure
After you install tc Server, the CATALINA_HOME and
CATALINA_BASE directories contain the following
sub-directories. As a reminder, when using the ASF directory layout,
CATALINA_HOME and CATALINA_BASE are the
same.
- CATALINA_HOME/bin: ASF layout only.
Startup, shutdown, and other scripts, as well as tc Server binary
files. The *.sh files (for Unix systems) are functional
duplicates of the *.bat files (for Windows
systems).
- CATALINA_BASE/bin: SpringSource layout only.
Contains the tcserver-ctl.* scripts to start and stop
tc Server, as well as the setenv.* scripts.
- CATALINA_BASE/conf: Contains the
configuration files for the tc Server instance, such as
server.xml, web.xml,
context.xml, and so on.
- CATALINA_BASE/lib: Contains resources
shared by all Web applications deployed to the tc Server
instance.
- CATALINA_BASE/logs: Location of the logs
files.
- CATALINA_BASE/webapps: Deployment directory
for the Web applications deployed to the tc Server instance.
- CATALINA_BASE/work: Temporary work
directory for all deployed Web applications.
- CATALINA_BASE/temp: Directory used by the
JVM for temporary files.
tc Server Configuration Files
You configure a particular tc Server instance by changing its
configuration files (either by editing the XML file by hand or using AMS);
later chapters of the documentation describe how to do this. All the
configuration files for a tc Server are located in its
CATALINA_BASE/conf directory. The most important
configuration files are as follows:
- server.xml: Main configuration file for a tc Server
instance. It configures the behavior of the servlet/JSP
container. By default, the server.xml file for a tc
Server instance uses variable substitution for configuration properties
that must be unique across multiple server instances computer, such
as HTTP and JMX port numbers. These variables take the form
${var}. For example, the variable for the
HTTP port that tc Server listens to is ${http.port}.
The specific values for these variables for a particular server instance
are stored in the conf/catalina.properties file, in
the same directory as the server.xml file.
- catalina.properties: Properties file that contains the
server instance-specific values for variables in the
server.xml file.
- context.xml: Configures the context that is loaded by all
Web applications deployed to the tc Server instance.
- web.xml: Default web.xml file that is
loaded by all deployed Web applications, in addition to their
individual web.xml files.
- wrapper.conf: Windows only. Configures the Java Service
Wrapper from Tanuki Software
used to install the tc Server instance as a Windows service. The
Wrapper correctly handles user log outs under Windows, service
dependencies, and the ability to run services which interact with the
desktop.
Differences between the SpringSource and ASF Layouts of tc Server
SpringSource tc Server provides two "flavors" of the tc Server
application server itself, based on the layout of their installation
directories: ASF and SpringSource. ASF uses the standard Apache Tomcat
directory layout that current Apache users should instantly recognize. This
directory is located in
INSTALL_DIR/tcServer-6.0/tomcat-version, where version is the version of tc Server such as 6.0.20.C. This directory is
ready to use immediately, which means it includes a tc Server instance by
default.
The SpringSource layout is slightly different, mostly in that it
supports multiple instances of tc Server with a single set of
binaries. This adds the following value for customers:
- A single installation of tc Server (that uses the SpringSource layout) supports multiple running tc Server instances.
- One set of binaries means easy upgrades of all the associated instances.
- Multiple separate instances allows testing of configuration and code changes without touching the production instance.
The SpringSource layout also provides a script for easily creating new instances of tc Server. The SpringSource layout does not provide a default server
instance right after installation; you must create one using the script. For details, see Creating Instances in the SpringSource Layout.