From: Rich Bowen Date: Tue, 20 Sep 2011 11:28:02 +0000 (+0000) Subject: Adds some examples of using the ErrorLogFormat token handlers. X-Git-Tag: 2.3.15~216 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=96a5aeb12dc46f7d830578940b231a0603f4515d;p=apache Adds some examples of using the ErrorLogFormat token handlers. Standardizes the spelling of behavio(u)r to be consistent throughout the file. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1173086 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/mod/core.xml b/docs/manual/mod/core.xml index 2655ed70f6..4de06cb85a 100644 --- a/docs/manual/mod/core.xml +++ b/docs/manual/mod/core.xml @@ -1304,7 +1304,7 @@ in case of an error

Specifying connection or request as first parameter allows to specify additional formats, causing additional information to be logged when the first message is logged for a specific - connection or request, respectivly. This additional information is only + connection or request, respectively. This additional information is only logged once per connection/request. If a connection or request is processed without causing any log message, the additional information is not logged either.

@@ -1313,7 +1313,7 @@ in case of an error example, the Referer header is only present if the log message is associated to a request and the log message happens at a time when the Referer header has already been read from the client. If no output is - produced, the default behaviour is to delete everything from the preceeding + produced, the default behavior is to delete everything from the preceeding space character to the next space character. This means the log line is implicitly divided into fields on non-whitespace to whitespace transitions. If a format string item does not produce output, the whole field is @@ -1324,7 +1324,7 @@ in case of an error (percent space) is a zero-witdh field delimiter that does not produce any output.

-

The above behaviour can be changed by adding modifiers to the format +

The above behavior can be changed by adding modifiers to the format string item. A - (minus) modifier causes a minus to be logged if the respective item does not produce any output. In once-per-connection/request formats, it is also possible to use the + (plus) modifier. If an @@ -1336,6 +1336,29 @@ in case of an error message is not higher than the specified log severity level. The number can range from 1 (alert) over 4 (warn) and 7 (debug) to 15 (trace8).

+ + + + + + + + + + + + + + + + + + + + +
Modified TokenMeaning
%-{Referer}iLogs a - if Referer is not set.
%+{Referer}iOmits the entire line if Referer is not set.
%4{Referer}iLogs the Referer only if the log message severity + is higher than 4.
+

Some format string items accept additional parameters in braces.

@@ -1346,73 +1369,73 @@ in case of an error - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -1983,7 +2006,7 @@ wildcard matching available in 2.3.6 and laterfail with an error saying the directory cannot be found.

-

For further control over the behaviour of the server when no files or +

For further control over the behavior of the server when no files or directories match, prefix the path with the modifiers optional or strict. If optional is specified, any wildcard file or directory that does not match will be silently ignored. If @@ -3971,7 +3994,7 @@ handler Note

Because SetHandler overrides default handlers, - normal behaviour such as handling of URLs ending in a slash (/) as + normal behavior such as handling of URLs ending in a slash (/) as directories or index files is suppressed.

@@ -4078,10 +4101,10 @@ certain events before failing a request TraceEnable -Determines the behaviour on TRACE requests +Determines the behavior on TRACE requests TraceEnable [on|off|extended] TraceEnable on -server configvirtual host +contextlist>server configvirtual host Available in Apache HTTP Server 1.3.34, 2.0.55 and later
%% The percent sign
%...a
%a Remote IP-address and port
%...A
%A Local IP-address and port
%...{name}e
%{name}e Request environment variable name
%...E
%E APR/OS error status code and string
%...F
%F Source file name and line number of the log call
%...{name}i
%{name}i Request header name
%...k
%k Number of keep-alive requests on this connection
%...l
%l Loglevel of the message
%...L
%L Log ID of the request
%...{c}L
%{c}L Log ID of the connection
%...{C}L
%{C}L Log ID of the connection if used in connection scope, empty otherwise
%...m
%m Name of the module logging the message
%M The actual log message
%...{name}n
%{name}n Request note name
%...P
%P Process ID of current process
%...T
%T Thread ID of current thread
%...{g}T
%{g}T System unique thread ID of current thread (the same ID as displayed by e.g. top; currently Linux only)
%...t
%t The current time
%...{u}t
%{u}t The current time including micro-seconds
%...{cu}t
%{cu}t The current time in compact ISO 8601 format, including micro-seconds
%...v
%v The canonical ServerName of the current server.
%...V
%V The server name of the server serving the request according to the UseCanonicalName setting.