Chapter 3: Tomcat Installation Web applications, and a

Chapter 3: Tomcat Installation Web applications, and a global configuration file. Later chapters discuss these files in greater detail. . logs: The /logs directory contains the server logs. . lib: The /lib directory contains all the JAR files used by Tomcat. . webapps: This directory contains all the Web applications provided with Tomcat by default. This includes the Tomcat manager application that is discussed in Chapter 8 . User-developed Web applications will also be deployed to this directory. The structure of the webapps directory is discussed in greater detail in Chapter 7 . . work: The work directory contains temporary files, precompiled JSP pages, and other intermediate files. Installing APR An optional component with Tomcat is APR, or the Apache Portable Runtime. This is a library that was originally developed as a part of the Apache 2 Web server, but is now used in many other projects. Use of this library in Tomcat improves stability and performance, especially when Tomcat is used to connect to a native Web server like Apache. If you see a message such as the following: INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path it is because the APR library is missing at Tomcat startup time. This is not an error, as the APR support is optional. Locations for APR native library binaries for some platforms are listed at http://tomcat.apache .org/tomcat-6.0-doc/apr.html; for example, Windows binaries are available from http:// tomcat.heanet.ie/native/. Download and save the tcnative-1.dll file from this Web site to the /bin directory. This DLL contains the native binaries for APR as well as for OpenSSL. For Linux/Unix, you need to install this from source. . If you don t have APR installed on your machine, download the source from http://apr .apache.org. Install APR using the following steps as the root user to install the APR in its default location (/usr/local/apr). If running as a non-root user, use the –prefixoption with configureto specify another install location. $ tar zxvf apr-x.y.z.tar.gz $ cd apr-x.y.z $ ./buildconf $ ./configure $ make install

For reliable and cheap web hosting services please check javaweb hosting website.

Comments are closed.