Server Bundle Logging
The components of the server bundle almost exclusively use Log4j to direct log output. The only exception is Derby, which does not use an external logging provider at all.
Out of the box, the server bundle writes the following log files:
- captures debug and error output from the Cosmo and Scooby webapps, the Jackrabbit repository, and Tomcat. Rotated when the file reaches 1000KB in size. One old log will be maintained (with the
- HTTP access log. Rotated at midnight each night. Old logs are not cleaned up.
- Derby startup notices and errors. Not rotated. It will not grow quickly, usually only containing startup notices. The file is appended to by default; to cause the file to be overwritten when Tomcat restarts, set the environment variable
$OSAFSRV_DERBY_ERROR_LOG_APPEND appropriately (see ServerBundleStartupConfiguration for more information).
- Anything written to
STDOUT. This file is not rotated. It will very rarely contain anything. Neither Cosmo nor Scooby uses
Logging to Other Places
Some server administrators prefer to send debug and error log messages to
, syslog, and other locations.
and configure a different appender.
For example, you can replace
by configuring a ConsoleAppender?
as the root appender:
<appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
Set the environment variable
to a different filesystem location (see ServerBundleStartupConfiguration
for more information). Derby cannot be configured to log to
There is one other wrinkle regarding
. Tomcat's startup script redirects
. You'll have to edit
to remove this redirection if you don't want
captured in that file. Don't worry, this task is simple enough for a blindfolded, no-armed monkey.
Turning Off Access Logging in the Bundled Distribution
In some cases, the server administrator will not need access logging (for example, when the server is run behind a reverse proxy). You can do this by removing the following element from
directory="../logs" prefix="access." suffix=".log"
for more startup configuration options
for more information about Log4j.
for more information on Tomcat Access Log Valve configuration.