1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
4 <TITLE>Apache module mod_status</TITLE>
6 <!-- Background white, links blue (unvisited), navy (visited), red (active) -->
15 <!--#include virtual="header.html" -->
17 <blockquote><strong>Warning:</strong>
18 This document has not been updated to take into account changes
19 made in the 2.0 version of the Apache HTTP Server. Some of the
20 information may still be relevant, but please use it
24 <H1 ALIGN="CENTER">Module mod_status</H1>
26 <p>This module provides information on server activity and
30 HREF="module-dict.html#Status"
32 ><STRONG>Status:</STRONG></A> Base
35 HREF="module-dict.html#SourceFile"
37 ><STRONG>Source File:</STRONG></A> mod_status.c
40 HREF="module-dict.html#ModuleIdentifier"
42 ><STRONG>Module Identifier:</STRONG></A> status_module
45 HREF="module-dict.html#Compatibility"
47 ><STRONG>Compatibility:</STRONG></A> Available in Apache 1.1 and later.
53 <p>The Status module allows a server administrator to find out how well
54 their server is performing. A HTML page is presented that gives
55 the current server statistics in an easily readable form. If required
56 this page can be made to automatically refresh (given a compatible
57 browser). Another page gives a simple machine-readable list of the current
61 The details given are:
63 <LI>The number of children serving requests
64 <LI>The number of idle children
65 <LI>The status of each child, the number of requests that child has
66 performed and the total number of bytes served by the child (*)
67 <LI>A total number of accesses and byte count served (*)
68 <LI>The time the server was started/restarted and the
69 time it has been running for
70 <LI>Averages giving the number of requests per second,
71 the number of bytes served per second and the average number
72 of bytes per request (*)
73 <LI>The current percentage CPU used by each child and in total by
75 <LI>The current hosts and requests being processed (*)
78 A compile-time option must be used to display the details marked "(*)" as
79 the instrumentation required for obtaining these statistics does not
80 exist within standard Apache.
85 <li><a href="#extendedstatus">ExtendedStatus</a></li>
89 <H2>Enabling Status Support</H2>
91 To enable status reports only for browsers from the foo.com
92 domain add this code to your <CODE>access.conf</CODE> configuration file
94 <Location /server-status>
95 SetHandler server-status
103 You can now access server statistics by using a Web browser to access the
104 page <CODE>http://your.server.name/server-status</CODE>
106 Note that mod_status will only work when you are running Apache in
107 <A HREF="core.html#servertype">standalone</A> mode and not
108 <A HREF="core.html#servertype">inetd</A> mode.
110 <H3>Automatic Updates</H3>
111 You can get the status page to update itself automatically if you have
112 a browser that supports "refresh". Access the page
113 <CODE>http://your.server.name/server-status?refresh=N</CODE> to refresh the
114 page every N seconds.
115 <H3>Machine Readable Status File</H3>
116 A machine-readable version of the status file is available by accessing the
117 page <CODE>http://your.server.name/server-status?auto</CODE>. This is useful
118 when automatically run, see the Perl program in the <CODE>/support</CODE>
119 directory of Apache, <CODE>log_server_status</CODE>.
123 It should be noted that if <SAMP>mod_status</SAMP> is compiled into
124 the server, its handler capability is available in <EM>all</EM>
125 configuration files, including <EM>per</EM>-directory files
126 (<EM>e.g.</EM>, <SAMP>.htaccess</SAMP>). This may have
127 security-related ramifications for your site.
133 <H2><A NAME="extendedstatus">ExtendedStatus directive</A></H2>
134 <!--%plaintext <?INDEX {\tt ExtendedStatus} directive> -->
136 HREF="directive-dict.html#Syntax"
138 ><STRONG>Syntax:</STRONG></A> ExtendedStatus On|Off<BR>
140 HREF="directive-dict.html#Default"
142 ><STRONG>Default:</STRONG></A> <CODE>ExtendedStatus Off</CODE><BR>
144 HREF="directive-dict.html#Context"
146 ><STRONG>Context:</STRONG></A> server config <BR>
148 HREF="directive-dict.html#Status"
150 ><STRONG>Status:</STRONG></A> Base<BR>
152 HREF="directive-dict.html#Module"
154 ><STRONG>Module:</STRONG></A> mod_status<BR>
156 HREF="directive-dict.html#Compatibility"
158 ><STRONG>Compatibility:</STRONG></A> ExtendedStatus is only available
159 in Apache 1.3.2 and later.
162 This directive controls whether the server keeps track of extended
163 status information for each request. This is only useful if the status module
164 is enabled on the server.
167 This setting applies to the entire server, and cannot be enabled or
168 disabled on a virtualhost-by-virtualhost basis.
171 <!--#include virtual="footer.html" -->