]> granicus.if.org Git - apache/blob - docs/manual/mod/mod_status.html.en
Documentation rebuild after recent commits
[apache] / docs / manual / mod / mod_status.html.en
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head>
4 <meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type" />
5 <!--
6         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
7               This file is generated from xml source: DO NOT EDIT
8         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
9       -->
10 <title>mod_status - Apache HTTP Server Version 2.5</title>
11 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
12 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
13 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" />
14 <script src="../style/scripts/prettify.min.js" type="text/javascript">
15 </script>
16
17 <link href="../images/favicon.ico" rel="shortcut icon" /></head>
18 <body>
19 <div id="page-header">
20 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/quickreference.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
21 <p class="apache">Apache HTTP Server Version 2.5</p>
22 <img alt="" src="../images/feather.png" /></div>
23 <div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
24 <div id="path">
25 <a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP Server</a> &gt; <a href="http://httpd.apache.org/docs/">Documentation</a> &gt; <a href="../">Version 2.5</a> &gt; <a href="./">Modules</a></div>
26 <div id="page-content">
27 <div id="preamble"><h1>Apache Module mod_status</h1>
28 <div class="toplang">
29 <p><span>Available Languages: </span><a href="../en/mod/mod_status.html" title="English">&nbsp;en&nbsp;</a> |
30 <a href="../fr/mod/mod_status.html" hreflang="fr" rel="alternate" title="Français">&nbsp;fr&nbsp;</a> |
31 <a href="../ja/mod/mod_status.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
32 <a href="../ko/mod/mod_status.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a> |
33 <a href="../tr/mod/mod_status.html" hreflang="tr" rel="alternate" title="Türkçe">&nbsp;tr&nbsp;</a></p>
34 </div>
35 <table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Provides information on server activity and
36 performance</td></tr>
37 <tr><th><a href="module-dict.html#Status">Status:</a></th><td>Base</td></tr>
38 <tr><th><a href="module-dict.html#ModuleIdentifier">Module Identifier:</a></th><td>status_module</td></tr>
39 <tr><th><a href="module-dict.html#SourceFile">Source File:</a></th><td>mod_status.c</td></tr></table>
40 <h3>Summary</h3>
41
42     <p>The Status module allows a server administrator to find out
43     how well their server is performing. A HTML page is presented
44     that gives the current server statistics in an easily readable
45     form. If required this page can be made to automatically
46     refresh (given a compatible browser). Another page gives a
47     simple machine-readable list of the current server state.</p>
48
49     <p>The details given are:</p>
50
51     <ul>
52       <li>The number of worker serving requests</li>
53
54       <li>The number of idle worker</li>
55
56       <li>The status of each worker, the number of requests that
57       worker has performed and the total number of bytes served by
58       the worker (*)</li>
59
60       <li>A total number of accesses and byte count served (*)</li>
61
62       <li>The time the server was started/restarted and the time it
63       has been running for</li>
64
65       <li>Averages giving the number of requests per second, the
66       number of bytes served per second and the average number of
67       bytes per request (*)</li>
68
69       <li>The current percentage CPU used by each worker and in
70       total by all workers combined (*)</li>
71
72       <li>The current hosts and requests being processed (*)</li>
73     </ul>
74
75     <p>The lines marked "(*)" are only available if
76     <code class="directive"><a href="../mod/core.html#extendedstatus">ExtendedStatus</a></code>
77     is <code>On</code>.  In version 2.3.6, loading mod_status will
78     toggle <code class="directive"><a href="../mod/core.html#extendedstatus">ExtendedStatus</a></code> On
79     by default.</p>
80 </div>
81 <div id="quickview"><h3>Topics</h3>
82 <ul id="topics">
83 <li><img alt="" src="../images/down.gif" /> <a href="#enable">Enabling Status Support</a></li>
84 <li><img alt="" src="../images/down.gif" /> <a href="#autoupdate">Automatic Updates</a></li>
85 <li><img alt="" src="../images/down.gif" /> <a href="#machinereadable">Machine Readable Status File</a></li>
86 <li><img alt="" src="../images/down.gif" /> <a href="#troubleshoot">Using server-status to troubleshoot</a></li>
87 </ul><h3 class="directives">Directives</h3>
88 <p>This module provides no
89             directives.</p>
90 <h3>Bugfix checklist</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">httpd changelog</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&amp;list_id=144532&amp;product=Apache%20httpd-2&amp;query_format=specific&amp;order=changeddate%20DESC%2Cpriority%2Cbug_severity&amp;component=mod_status">Known issues</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&amp;component=mod_status">Report a bug</a></li></ul><h3>See also</h3>
91 <ul class="seealso">
92 <li><a href="#comments_section">Comments</a></li></ul></div>
93 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
94 <div class="section">
95 <h2><a name="enable" id="enable">Enabling Status Support</a></h2>
96     
97
98     <p>To enable status reports only for browsers from the example.com
99     domain add this code to your <code>httpd.conf</code>
100     configuration file</p>
101 <pre class="prettyprint lang-config">&lt;Location "/server-status"&gt;
102     SetHandler server-status
103     Require host example.com
104 &lt;/Location&gt;</pre>
105
106
107     <p>You can now access server statistics by using a Web browser
108     to access the page
109     <code>http://your.server.name/server-status</code></p>
110 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
111 <div class="section">
112 <h2><a name="autoupdate" id="autoupdate">Automatic Updates</a></h2>
113
114     
115     <p>You can get the status page to update itself automatically if
116     you have a browser that supports "refresh". Access the page
117     <code>http://your.server.name/server-status?refresh=N</code> to
118     refresh the page every N seconds.</p>
119
120 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
121 <div class="section">
122 <h2><a name="machinereadable" id="machinereadable">Machine Readable Status File</a></h2>
123
124     
125     <p>A machine-readable version of the status file is available by
126     accessing the page
127     <code>http://your.server.name/server-status?auto</code>. This
128     is useful when automatically run, see the Perl program
129     <code>log_server_status</code>, which you will find in the
130     <code>/support</code> directory of your Apache HTTP Server installation.</p>
131
132     <div class="note">
133       <strong>It should be noted that if <code class="module"><a href="../mod/mod_status.html">mod_status</a></code> is
134       loaded into the server, its handler capability is available
135       in <em>all</em> configuration files, including
136       <em>per</em>-directory files (<em>e.g.</em>,
137       <code>.htaccess</code>). This may have security-related
138       ramifications for your site.</strong>
139     </div>
140
141 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
142 <div class="section">
143 <h2><a name="troubleshoot" id="troubleshoot">Using server-status to troubleshoot</a></h2>
144     
145
146     <p>The <code>server-status</code> page may be used as a starting
147     place for troubleshooting a situation where your server is consuming
148     all available resources (CPU or memory), and you wish to identify
149     which requests or clients are causing the problem.</p>
150
151     <p>First, ensure that you have <code class="directive"><a href="../mod/core.html#extendedstatus">ExtendedStatus</a></code> set on, so that you can see
152     the full request and client information for each child or
153     thread.</p>
154
155     <p>Now look in your process list (using <code>top</code>, or similar
156     process viewing utility) to identify the specific processes that are
157     the main culprits. Order the output of <code>top</code> by CPU
158     usage, or memory usage, depending on what problem you're trying to
159     address.</p>
160
161     <p>Reload the <code>server-status</code> page, and look for those process
162     ids, and you'll be able to see what request is being served by that
163     process, for what client. Requests are transient, so you may need to
164     try several times before you catch it in the act, so to speak.</p>
165
166     <p>This process <em>should</em> give you some idea what client, or
167     what type of requests, are primarily responsible for your load
168     problems. Often you will identify a particular web application that
169     is misbehaving, or a particular client that is attacking your
170     site.</p>
171
172 </div>
173 </div>
174 <div class="bottomlang">
175 <p><span>Available Languages: </span><a href="../en/mod/mod_status.html" title="English">&nbsp;en&nbsp;</a> |
176 <a href="../fr/mod/mod_status.html" hreflang="fr" rel="alternate" title="Français">&nbsp;fr&nbsp;</a> |
177 <a href="../ja/mod/mod_status.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
178 <a href="../ko/mod/mod_status.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a> |
179 <a href="../tr/mod/mod_status.html" hreflang="tr" rel="alternate" title="Türkçe">&nbsp;tr&nbsp;</a></p>
180 </div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&amp;A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our <a href="http://httpd.apache.org/lists.html">mailing lists</a>.</div>
181 <script type="text/javascript"><!--//--><![CDATA[//><!--
182 var comments_shortname = 'httpd';
183 var comments_identifier = 'http://httpd.apache.org/docs/trunk/mod/mod_status.html';
184 (function(w, d) {
185     if (w.location.hostname.toLowerCase() == "httpd.apache.org") {
186         d.write('<div id="comments_thread"><\/div>');
187         var s = d.createElement('script');
188         s.type = 'text/javascript';
189         s.async = true;
190         s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier;
191         (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s);
192     }
193     else {
194         d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>');
195     }
196 })(window, document);
197 //--><!]]></script></div><div id="footer">
198 <p class="apache">Copyright 2016 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
199 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/quickreference.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!--
200 if (typeof(prettyPrint) !== 'undefined') {
201     prettyPrint();
202 }
203 //--><!]]></script>
204 </body></html>