mod_log_config.xml revision 05a9ee8994d646c0067b6ea6ec64551e1e0c56ab
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<!DOCTYPE modulesynopsis SYSTEM "/style/modulesynopsis.dtd">
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<?xml-stylesheet type="text/xsl" href="/style/manual.en.xsl"?>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<!-- $LastChangedRevision$ -->
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye Licensed to the Apache Software Foundation (ASF) under one or more
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye contributor license agreements. See the NOTICE file distributed with
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye this work for additional information regarding copyright ownership.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye The ASF licenses this file to You under the Apache License, Version 2.0
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye (the "License"); you may not use this file except in compliance with
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye the License. You may obtain a copy of the License at
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye Unless required by applicable law or agreed to in writing, software
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye distributed under the License is distributed on an "AS IS" BASIS,
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye See the License for the specific language governing permissions and
a638f353bad3ee605c93aa9808d707dd8198bf8aKnut Anders Hatlen limitations under the License.
a638f353bad3ee605c93aa9808d707dd8198bf8aKnut Anders Hatlen<modulesynopsis metafile="mod_log_config.xml.meta">
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye<description>Logging of the requests made to the server</description>
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye <p>This module provides for flexible logging of client
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok requests. Logs are written in a customizable format, and may be
bef1c30dbcd8f72a02f0a247cabf605f282bbcbdKnut Anders Hatlen written directly to a file, or to an external program.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye Conditional logging is provided so that individual requests may
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal be included or excluded from the logs based on characteristics
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal of the request.</p>
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok <p>Three directives are provided by this module:
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok <directive module="mod_log_config">TransferLog</directive> to create
eb1776903fd1f998009e97470a65fba8a499a0d9Lubos Kosco a log file, <directive module="mod_log_config">LogFormat</directive>
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST to set a custom format, and <directive module="mod_log_config"
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye >CustomLog</directive> to define a log file and format in one
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye step. The <directive>TransferLog</directive> and <directive
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye >CustomLog</directive> directives can be used multiple times in each
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye server to cause each request to be logged to multiple files.</p>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<seealso><a href="/logs.html">Apache Log Files</a></seealso>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<section id="formats"><title>Custom Log Formats</title>
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST <p>The format argument to the <directive module="mod_log_config"
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye >LogFormat</directive> and <directive module="mod_log_config"
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye >CustomLog</directive> directives is a string. This string is
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye used to log each request to the log file. It can contain literal
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye characters copied into the log files and the C-style control
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal characters "\n" and "\t" to represent new-lines and tabs.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye Literal quotes and backslashes should be escaped with
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye backslashes.</p>
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye <p>The characteristics of the request itself are logged by
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye placing "<code>%</code>" directives in the format string, which are
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye replaced in the log file by the values as follows:</p>
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye <columnspec><column width=".2"/><column width=".8"/></columnspec>
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <td>Size of response in bytes, excluding HTTP headers.</td></tr>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>Size of response in bytes, excluding HTTP headers. In CLF format, <em>i.e.</em>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal a '<code>-</code>' rather than a 0 when no bytes are sent.</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <tr><td><code>%{<var>VARNAME</var>}C</code></td>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The contents of cookie <var>VARNAME</var> in the request sent
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal to the server. Only version 0 cookies are fully supported.</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The time taken to serve the request, in microseconds.</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <tr><td><code>%{<var>VARNAME</var>}e</code></td>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The contents of the environment variable
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>Remote hostname. Will log the IP address if <directive
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal module="core">HostnameLookups</directive> is set to
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <code>Off</code>, which is the default.</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <tr><td><code>%{<var>VARNAME</var>}i</code></td>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The contents of <code><var>VARNAME</var>:</code> header line(s)
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal in the request sent to the server. Changes made by other
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal modules (e.g. <module>mod_headers</module>) affect this.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>Number of keepalive requests handled on this connection. Interesting if
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye <directive module="core">KeepAlive</directive> is being used, so that,
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye for example, a '1' means the first keepalive request after the initial
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye one, '2' the second, etc...;
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye otherwise this is always 0 (indicating the initial request).</td></tr>
0e41d6423b8ed191b1c438091dca3da7d71b6569Trond Norbye <td>Remote logname (from identd, if supplied). This will return a
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye dash unless <module>mod_ident</module> is present and <directive
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye module="mod_ident">IdentityCheck</directive> is set
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye <td>The request log ID from the error log (or '-' if nothing has been
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye logged to the error log for this request). Look for the
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye matching error log line to see what request caused what error.</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>%{<var>VARNAME</var>}n</code></td>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>The contents of note <var>VARNAME</var> from another
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>%{<var>VARNAME</var>}o</code></td>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>The contents of <code><var>VARNAME</var>:</code> header line(s)
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>The canonical port of the server serving the request.</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>%{<var>format</var>}p</code></td>
0e41d6423b8ed191b1c438091dca3da7d71b6569Trond Norbye <td>The canonical port of the server serving the request, or the
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye server's actual port, or the client's actual port. Valid formats
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal are <code>canonical</code>, <code>local</code>, or <code>remote</code>.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>The process ID of the child that serviced the request.</td></tr>
b35e8d4188467587834c9713725171aa0e6ce2deJorgen Austvik <tr><td><code>%{<var>format</var>}P</code></td>
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal <td>The process ID or thread ID of the child that serviced the
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal request. Valid formats are <code>pid</code>, <code>tid</code>,
b35e8d4188467587834c9713725171aa0e6ce2deJorgen Austvik and <code>hextid</code>. <code>hextid</code> requires APR 1.2.0 or
685697e8aa716bef7a12e351b4fc3a93b3025f09Vladimir Kotal <td>The query string (prepended with a <code>?</code> if a query
685697e8aa716bef7a12e351b4fc3a93b3025f09Vladimir Kotal string exists, otherwise an empty string).</td></tr>
685697e8aa716bef7a12e351b4fc3a93b3025f09Vladimir Kotal <td>The handler generating the response (if any).</td></tr>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>Status. For requests that have been internally redirected, this is
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye the status of the <em>original</em> request. Use <code>%>s</code>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>Time the request was received, in the format <code>[18/Sep/2011:19:18:28 -0400]</code>.
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye The last number indicates the timezone offset from GMT</td></tr>
2aef10a5d2ebeaeb6b9cb6fed41933d19a76292fTrond Norbye <tr><td><code>%{<var>format</var>}t</code></td>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>The time, in the form given by format, which should be in
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye an extended <code>strftime(3)</code> format (potentially localized).
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye If the format starts with <code>begin:</code> (default) the time is taken
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye at the beginning of the request processing. If it starts with
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <code>end:</code> it is the time when the log entry gets written,
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST close to the end of the request processing. In addition to the formats
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye supported by <code>strftime(3)</code>, the following format tokens are
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>sec</code></td><td>number of seconds since the Epoch</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>msec</code></td><td>number of milliseconds since the Epoch</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>usec</code></td><td>number of microseconds since the Epoch</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <tr><td><code>msec_frac</code></td><td>millisecond fraction</td></tr>
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal <tr><td><code>usec_frac</code></td><td>microsecond fraction</td></tr>
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal These tokens can not be combined with each other or <code>strftime(3)</code>
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal formatting in the same format string. You can use multiple
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <code>%{<var>format</var>}t</code> tokens instead.
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The time taken to serve the request, in seconds.</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>Remote user if the request was authenticated. May be bogus if return status
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal (<code>%s</code>) is 401 (unauthorized).</td></tr>
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal <td>The URL path requested, not including any query string.</td></tr>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <td>The canonical <directive module="core">ServerName</directive>
685697e8aa716bef7a12e351b4fc3a93b3025f09Vladimir Kotal <td>The server name according to the <directive module="core"
a04de4b09ef6a455ea16df94e6db7a73240e6bb6Vladimir Kotal >UseCanonicalName</directive> setting.</td></tr>
0e41d6423b8ed191b1c438091dca3da7d71b6569Trond Norbye <td>Connection status when response is completed:
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <columnspec><column width=".2"/><column width=".6"/></columnspec>
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST <td>Connection aborted before the response completed.</td></tr>
1b140988201ab90ef3f2e0d9a05ae044b34def2bTrond Norbye <td>Connection may be kept alive after the response is
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST <td>Connection will be closed after the response is
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>Bytes received, including request and headers. Cannot be zero.
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye You need to enable <module>mod_logio</module> to use this.</td></tr>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <td>Bytes sent, including headers. Cannot be zero. You need to
0e41d6423b8ed191b1c438091dca3da7d71b6569Trond Norbye enable <module>mod_logio</module> to use this.</td></tr>
3b4581477b54ccb592cd154399ee30851ae74bb8Knut Anders Hatlen <section id="modifiers"><title>Modifiers</title>
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal <p>Particular items can be restricted to print only for
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal responses with specific HTTP status codes by placing a
74863c57395ccb10e3844c013df6b42c49bcf874Vladimir Kotal comma-separated list of status codes immediately following the
3b4581477b54ccb592cd154399ee30851ae74bb8Knut Anders Hatlen "%". The status code list may be peceded by a "<code>!</code>" to
3b4581477b54ccb592cd154399ee30851ae74bb8Knut Anders Hatlen indicate negation.</p>
3b4581477b54ccb592cd154399ee30851ae74bb8Knut Anders Hatlen <columnspec><column width=".2"/><column width=".8"/></columnspec>
a638f353bad3ee605c93aa9808d707dd8198bf8aKnut Anders Hatlen <td><code>%400,501{User-agent}i</code></td>
0e41d6423b8ed191b1c438091dca3da7d71b6569Trond Norbye <td>Logs <code>User-agent</code> on 400 errors and 501 errors only. For
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye other status codes, the literal string <code>"-"</code> will be
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <tr><td><code>%!200,304,302{Referer}i</code></td>
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye <td>Logs <code>Referer</code> on all requests that do
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <em>not</em> return one of the three specified codes,
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye <p>The modifiers "<" and ">" can be used for requests that
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye have been internally redirected to choose whether the original
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye or final (respectively) request should be consulted. By
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye default, the <code>%</code> directives <code>%s, %U, %T,
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye %D,</code> and <code>%r</code> look at the original request
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye while all others look at the final request. So for example,
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <code>%>s</code> can be used to record the final status of
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye the request and <code>%<u</code> can be used to record the
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye original authenticated user on a request that is internally
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye redirected to an unauthenticated resource.</p>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <section id="format-notes"><title>Format Notes</title>
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <p>For security reasons, starting with version 2.0.46,
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye non-printable and other special characters in <code>%r</code>,
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <code>%i</code> and <code>%o</code> are escaped using
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <code>\x<var>hh</var></code> sequences, where <var>hh</var>
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye stands for the hexadecimal representation of the raw
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye byte. Exceptions from this rule are <code>"</code> and
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <code>\</code>, which are escaped by prepending a backslash, and
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye all whitespace characters, which are written in their C-style
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye notation (<code>\n</code>, <code>\t</code>, etc). In versions
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye prior to 2.0.46, no escaping was performed on these strings so
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye you had to be quite careful when dealing with raw log files.</p>
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <p>In httpd 2.0, unlike 1.3, the <code>%b</code> and
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye <code>%B</code> format strings do not represent the number of
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye bytes sent to the client, but simply the size in bytes of the
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye HTTP response (which will differ, for instance, if the
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye connection is aborted, or if SSL is used). The <code>%O</code>
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye format provided by <module>mod_logio</module> will log the
85b9b88f3a239f3d0014bc5a2b699c1eeb50a47fTrond Norbye actual number of bytes sent over the network.</p>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye <p>Note: <module>mod_cache</module> is implemented as a
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye quick-handler and not as a standard handler. Therefore, the
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <code>%R</code> format string will not return any handler
ff5eba819da0cf7964d884630fb13262ef12c505Trond Norbye information when content caching is involved.</p>
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <p>Some commonly used log format strings are:</p>
91bdeb6c93fee2ac50a6ba73fcc63b96effc3340Trond Norbye <dd><code>"%h %l %u %t \"%r\" %>s %b"</code></dd>
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye <dd><code>"%v %h %l %u %t \"%r\" %>s %b"</code></dd>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <dd><code>"%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye <p>You can use the <code>%{format}t</code> directive multiple
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye times to build up a time format using the extended format tokens
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye<dd><code>"%{%d/%b/%Y %T}t.%{msec_frac}t %{%z}t"</code></dd>
e6136611a7a3b7d87fc68cdbbcdf42c69a7fb50dTrond Norbye<section id="security"><title>Security Considerations</title>
2aef10a5d2ebeaeb6b9cb6fed41933d19a76292fTrond Norbye href="/misc/security_tips.html#serverroot">security tips</a>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye document for details on why your security could be compromised
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye if the directory where logfiles are stored is writable by
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye anyone other than the user that starts the server.</p>
d878aee8c1ee3ea5e330dd7bfebfe07c9dd19089Trond Norbye<directivesynopsis>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<description>Buffer log entries in memory before writing to disk</description>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<contextlist><context>server config</context></contextlist>
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok<compatibility>Available in versions 2.0.41 and later.</compatibility>
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok <p>The <directive>BufferedLogs</directive> directive causes
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok <module>mod_log_config</module> to store several log entries in
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST memory and write them together to disk, rather than writing them
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok after each request. On some systems, this may result in more
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok efficient disk access and hence higher performance. It may be
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok set only once for the entire server; it cannot be configured
6336b638e9afd018de5f6c516eac4775d140fdaeJHKST per virtual-host.</p>
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok <note>This directive should be used with caution as a crash might
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok cause loss of logging data.</note>
a041b2b7edcc83a8c8b64689fbdb85321300431ejel+opengrok</directivesynopsis>
38115c792a2142d264ca2617b11962301f079c0aTrond Norbye<directivesynopsis>
CustomLog nongif-requests.log common env=!gif-image
CustomLog referer.log referer env=!localreferer