Xitami/5 generates access logs in the standard Apache format as well as custom formats.
Xitami/5 generates access logs in a variety of formats:
- CLF - NCSA/httpd common logging format.
- CLFX - W3C logging format as used by Apache. This is the default.
- Custom defined log format.
Xitami uses templating to produce the log files. The templates for the above predefined formats are:
- CLF - '$from - $user [$datetime] "$request" $status $sent'
- CLFX - '$from - $user [$datetime] "$request" $status $sent "$referer" "$agent"'
The log file format is specified by —access_log_format or /config/logging/access_log_format. If it is not one of the above three values, it is used as a template. The full list of template variables is:
- $agent - User-Agent header value
- $arguments - requested URI arguments
- $datetime - date/time in NCSA format
- $day - day as two digits
- $file - filename to which request was translated
- $from - client address, as dotted number
- $hh - hour, using 24-hour clock
- $method - HTTP method
- $mm - minutes as two digits
- $mon - month as two digits
- $path - requested URI path
- $query - query string, if any
- $recd - request size, in bytes
- $referer - Referer header
- $request - complete request line
- $sent - response size, in bytes
- $ss - seconds as two digits
- $status - response code, 3 digits
- $user - user name, if authenticated, else -
- $year - year as four digits
- $yy - year as two digits
- $VAR - environment variable VAR