Chapter 4: Tomcat Architecture CATALINA_HOME /bin /conf /lib
Chapter 4: Tomcat Architecture CATALINA_HOME /bin /conf /lib /logs /temp /webapps /work Figure 4-1: Tomcat directory structure bin Directory The bin directory contains the scripts and code required to execute the server. Depending on the version that you download, this directory may contain executable ( .exe) files for a Windows service installation, or it will just contain the standard Java starting scripts. Both Unix/Linux shell scripts ( .sh ) and Windows batch ( .bat) scripts exist here for the standard Tomcat download. Some JAR files also live in the bin directory, including bootstrap.jar, commons-daemon.jar, and tomcat-juli.jar . This directory is primarily used for starting and stopping Tomcat with either the startup or Catalina script. The startup.sh(bat) script is typically used for running Tomcat as a background process. Using the catalina.sh(bat) script allows you to have more fine-grained control over running Tomcat, such as running it as a foreground process, in debug mode. The startup.sh(bat) script actually runs catalina.sh(bat) and simply instructs it to run in the background. conf Directory The conf directory contains the files that are necessary to configure and set parameters for Tomcat when it executes. When Tomcat launches, it investigates the files in this directory and alters/creates the necessary objects and settings to run. The following is a list of the files along with a short description of their use. . catalina.policy: Contains the security policy statements that are implemented by the Java SecurityManager. It replaces the java.policyfile that came with your Java installation. It is used to prevent rogue code or JSPs from executing damaging code that can affect the container with calls such as system.exit(0). It is used only when Tomcat is launched with the -security command-line parameter. . catalina.properties: Contains lists of Java packages that cannot be overridden by executable Java code in servlets or JSPs, such as java.*or org.apache.tomcat.*, which could be a security risk. Also allows the setting to look for common JARs.
For high quality java hosting services please check tomcat web hosting website.