[deployment-guide/comm-rel: 525/727] Updated the LogFormat directive description.
Jaromir Hradilek
jhradile at fedoraproject.org
Tue Oct 19 13:09:04 UTC 2010
commit 58b94d3c72508117b39ba23102edf56c0c384323
Author: Jaromir Hradilek <jhradile at redhat.com>
Date: Tue Aug 31 14:11:50 2010 +0200
Updated the LogFormat directive description.
en-US/The_Apache_HTTP_Server.xml | 201 +++++++++++++++++++-------------------
1 files changed, 99 insertions(+), 102 deletions(-)
---
diff --git a/en-US/The_Apache_HTTP_Server.xml b/en-US/The_Apache_HTTP_Server.xml
index 987bdce..fc69547 100644
--- a/en-US/The_Apache_HTTP_Server.xml
+++ b/en-US/The_Apache_HTTP_Server.xml
@@ -1224,6 +1224,105 @@ ErrorDocument 404 /404-not_found.html</screen>
</example>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><option>LogFormat</option></term>
+ <listitem>
+ <para>
+ The <replaceable>LogFormat</replaceable> directive allows you to specify a log file format. It takes the following form:
+ </para>
+ <screen>LogFormat <replaceable>format</replaceable> <replaceable>name</replaceable></screen>
+ <para>
+ The <replaceable>format</replaceable> is a string consisting of options as described in <xref linkend="table-apache-httpdconf-logformat" />. The <replaceable>name</replaceable> can be used instead of the format string in the <option>CustomLog</option> directive.
+ </para>
+ <table id="table-apache-httpdconf-logformat">
+ <title>Common <option>LogFormat</option> options</title>
+ <tgroup cols="2">
+ <colspec colname="option" colnum="1" colwidth="10*" />
+ <colspec colname="description" colnum="2" colwidth="70*" />
+ <thead>
+ <row>
+ <entry>
+ Option
+ </entry>
+ <entry>
+ Description
+ </entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>
+ <option>%b</option>
+ </entry>
+ <entry>
+ Represents the size of the response in bytes.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%h</option>
+ </entry>
+ <entry>
+ Represents the IP address or hostname of a remote client.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%l</option>
+ </entry>
+ <entry>
+ Represents the remote log name if supplied. If not, a hyphen (that is, <literal>-</literal>) is used instead.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%r</option>
+ </entry>
+ <entry>
+ Represents the first line of the request string as it came from the browser or client.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%s</option>
+ </entry>
+ <entry>
+ Represents the status code.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%t</option>
+ </entry>
+ <entry>
+ Represents the date and time of the request.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%u</option>
+ </entry>
+ <entry>
+ If the authentication is required, it represents the remote user. If not, a hyphen (that is, <literal>-</literal>) is used instead.
+ </entry>
+ </row>
+ <row>
+ <entry>
+ <option>%{<replaceable>field</replaceable>}</option>
+ </entry>
+ <entry>
+ Represents the content of the HTTP header <replaceable>field</replaceable>. The common options include <option>%{Referer}</option> (the URL of the web page that referred the client to the server) and <option>%{User-Agent}</option> (the type of the web browser making the request).
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </table>
+ <example id="example-apache-httpdconf-logformat">
+ <title>Using the <option>LogFormat</option> directive</title>
+ <screen>LogFormat "%h %l %u %t \"%r\" %>s %b" common</screen>
+ </example>
+ </listitem>
+ </varlistentry>
</variablelist>
<formalpara id="s2-apache-indexoptions">
<title>IndexOptions</title>
@@ -1251,108 +1350,6 @@ ErrorDocument 404 /404-not_found.html</screen>
<para>
<command>IndexOptions</command> has a number of other parameters which can be set to control the appearance of server generated directories. The <command>IconHeight</command> and <command>IconWidth</command> parameters require the server to include HTML <command>HEIGHT</command> and <command>WIDTH</command> tags for the icons in server generated webpages. The <command>IconsAreLinks</command> parameter combines the graphical icon with the HTML link anchor, which contains the URL link target.
</para>
- <formalpara id="s2-apache-logformat">
- <title>LogFormat</title>
- <indexterm>
- <primary><command>LogFormat</command></primary>
- <secondary>Apache configuration directive</secondary>
- </indexterm>
- <indexterm>
- <primary>configuration directives, Apache</primary>
- <secondary><command>LogFormat</command></secondary>
- <tertiary>format options</tertiary>
- </indexterm>
- <indexterm>
- <primary>Apache HTTP Server</primary>
- <secondary>log files</secondary>
- <tertiary>format of</tertiary>
- </indexterm>
- <indexterm>
- <primary>Apache HTTP Server</primary>
- <secondary>log files</secondary>
- <tertiary>combined log file format</tertiary>
- </indexterm>
- <para>
- The <command>LogFormat</command> directive configures the format of the various Web server log files. The actual <command>LogFormat</command> used depends on the settings given in the <command>CustomLog</command> directive<!-- (refer to <xref linkend="s2-apache-customlog" />)-->.
- </para>
- </formalpara>
- <para>
- The following are the format options if the <command>CustomLog</command> directive is set to <command>combined</command>:
- </para>
- <variablelist>
- <varlistentry>
- <term><command>%h</command> (remote host's IP address or hostname)</term>
- <listitem>
- <para>
- Lists the remote IP address of the requesting client. If <command>HostnameLookups</command> is set to <option>on</option>, the client hostname is recorded unless it is not available from DNS.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%l</command> (rfc931)</term>
- <listitem>
- <para>
- Not used. A hyphen <keycap>-</keycap> appears in the log file for this field.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%u</command> (authenticated user)</term>
- <listitem>
- <para>
- Lists the username of the user recorded if authentication was required. Usually, this is not used, so a hyphen <keycap>-</keycap> appears in the log file for this field.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%t</command> (date)</term>
- <listitem>
- <para>
- Lists the date and time of the request.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%r</command> (request string)</term>
- <listitem>
- <para>
- Lists the request string exactly as it came from the browser or client.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%s</command> (status)</term>
- <listitem>
- <para>
- Lists the HTTP status code which was returned to the client host.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%b</command> (bytes)</term>
- <listitem>
- <para>
- Lists the size of the document.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%\"%{Referer}i\"</command> (referrer)</term>
- <listitem>
- <para>
- Lists the URL of the webpage which referred the client host to Web server.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><command>%\"%{User-Agent}i\"</command> (user-agent)</term>
- <listitem>
- <para>
- Lists the type of Web browser making the request.
- </para>
- </listitem>
- </varlistentry>
- </variablelist>
<formalpara id="s2-apache-loglevel">
<title>LogLevel</title>
<indexterm>
More information about the docs-commits
mailing list