All notes


Mac OS X easily install apache tomcat on Mac OS X.

brew install tomcat

# Homebrew keeps packages (known as kegs) in the Cellar, where you can check config and data files.
ls /usr/local/Cellar/
# Verify the Tomcat installation using homebrew’s handy “services” utility:
brew services list

brew services --help

catalina run
# Goto: http://localhost:8080/

# Modify username and password:
vim /usr/local/Cellar/tomcat/[version]/libexec/conf/tomcat-users.xml
# <user username="admin" password="password" roles="tomcat,manager-gui" />
# Now you can go to:
# http://localhost:8080/manager/html

# Deployed applications are usually then located under the directory:

Deploy a web app

It is NOT recommended to place "Context" elements directly in the server.xml file. This is because it makes modifying the Context configuration more invasive since the main conf/server.xml file cannot be reloaded without restarting Tomcat. context parameters.

Context elements may be explicitly defined:


juli, logging logging.

Apache Tomcat has its own implementation of several key elements of "java.util.logging API" - "JULI".


Usually done in the {catalina.base}/conf/ file. {catalina.base} may be: /usr/share/tomcat6.

catalina.out, localhost.*

stackOverflow: difference between localhost and catalina.

Find all detail in conf/ and conf/server.xml.

In short catalina is the container log file, localhost_access (only one defined in server.xml) the access log (= all requests like in httpd), localhost the log of the host and finally host-manager and manager the logs of the related web applications.


Catalina is Tomcat's servlet container. Catalina implements Sun Microsystems' specifications for servlet and JavaServer Pages (JSP).


Coyote is a Connector component for Tomcat that supports the HTTP 1.1 protocol as a web server.

Another Coyote Connector, Coyote JK, listens similarly but instead forwards its requests to another web server, such as Apache, using the JK protocol. This usually offers better performance.