]> granicus.if.org Git - apache/commitdiff
Add examples of using ErrorLog, particularly logging to syslog.
authorRich Bowen <rbowen@apache.org>
Mon, 28 Oct 2002 01:52:01 +0000 (01:52 +0000)
committerRich Bowen <rbowen@apache.org>
Mon, 28 Oct 2002 01:52:01 +0000 (01:52 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97318 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/mod/core.html.en
docs/manual/mod/core.xml

index 49c7468ebdc095cf05368541464151d7514d41a5..b7f094fd252b070ce4a5e20690fb1615ed94bdf7 100644 (file)
@@ -759,10 +759,20 @@ ErrorLog logs/error.log (Windows and OS/2)</code></td></tr><tr><th><a href="dire
     <p>The <code class="directive">ErrorLog</code> directive sets the name of
     the file to which the server will log any errors it encounters. If
     the <var>file-path</var> does not begin with a slash (/) then it is
-    assumed to be relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>. If the <var>file-path</var>
+    assumed to be relative to the <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
+
+    <div class="example"><h3>Example</h3><p><code>
+    ErrorLog /var/log/httpd/error_log
+    </code></p></div>
+    
+    <p>If the <var>file-path</var>
     begins with a pipe (|) then it is assumed to be a command to spawn
     to handle the error log.</p>
 
+    <div class="example"><h3>Example</h3><p><code>
+    ErrorLog "|/usr/local/bin/httpd_errors"
+    </code></p></div>
+
     <p>Using <code>syslog</code> instead of a filename enables logging
     via syslogd(8) if the system supports it. The default is to use
     syslog facility <code>local7</code>, but you can override this by
@@ -770,6 +780,10 @@ ErrorLog logs/error.log (Windows and OS/2)</code></td></tr><tr><th><a href="dire
     <var>facility</var> can be one of the names usually documented in
     syslog(1).</p>
 
+    <div class="example"><h3>Example</h3><p><code>
+    ErrorLog syslog:user
+    </code></p></div>
+
     <p>SECURITY: See the <a href="../misc/security_tips.html#serverroot">security tips</a>
     document for details on why your security could be compromised
     if the directory where logfiles are stored is writable by
index ae88d9b2318dd97759640983f5462407b5a5b195..03dd1ec54f261d1d0478d6aa1d6de8d399c1f76a 100644 (file)
@@ -851,10 +851,20 @@ ErrorLog logs/error.log (Windows and OS/2)</default>
     the file to which the server will log any errors it encounters. If
     the <var>file-path</var> does not begin with a slash (/) then it is
     assumed to be relative to the <directive
-    module="core">ServerRoot</directive>. If the <var>file-path</var>
+    module="core">ServerRoot</directive>.</p>
+
+    <example><title>Example</title>
+    ErrorLog /var/log/httpd/error_log
+    </example>
+    
+    <p>If the <var>file-path</var>
     begins with a pipe (|) then it is assumed to be a command to spawn
     to handle the error log.</p>
 
+    <example><title>Example</title>
+    ErrorLog "|/usr/local/bin/httpd_errors"
+    </example>
+
     <p>Using <code>syslog</code> instead of a filename enables logging
     via syslogd(8) if the system supports it. The default is to use
     syslog facility <code>local7</code>, but you can override this by
@@ -862,6 +872,10 @@ ErrorLog logs/error.log (Windows and OS/2)</default>
     <var>facility</var> can be one of the names usually documented in
     syslog(1).</p>
 
+    <example><title>Example</title>
+    ErrorLog syslog:user
+    </example>
+
     <p>SECURITY: See the <a
     href="../misc/security_tips.html#serverroot">security tips</a>
     document for details on why your security could be compromised