mpm_common.html.en revision 25f82ac9fc31b40fe2e7d1b834c7d9124b28cd4d
08cb74ca432a8c24e39f17dedce527e6a47b8001jerenkrantz<?xml version="1.0" encoding="ISO-8859-1"?>
08cb74ca432a8c24e39f17dedce527e6a47b8001jerenkrantz<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd This file is generated from xml source: DO NOT EDIT
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein -->
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<title>mpm_common - Apache HTTP Server</title>
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<link href="/style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/images/favicon.ico" rel="shortcut icon" /></head>
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<body>
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<div id="page-header">
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="/faq/">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p class="apache">Apache HTTP Server Version 2.3</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<img alt="" src="/images/feather.gif" /></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="/images/left.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div id="path">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<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.3</a> &gt; <a href="./">Modules</a></div>
cccd31fa4a72fe23cc3249c06db181b274a55a69gstein<div id="page-content">
1f6e6566a4ce31a0b95d5400c36d0aaff7a6e94agstein<div id="preamble"><h1>Apache MPM Common Directives</h1>
8a46775d163c06a8c51d1b0a3f2edfde945cb1d8stoddard<div class="toplang">
2fc50921b88defeb7127985dfe4b4130175e069ejwoolley<p><span>Available Languages: </span><a href="/de/mod/mpm_common.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein<a href="/en/mod/mpm_common.html" title="English">&nbsp;en&nbsp;</a> |
cccd31fa4a72fe23cc3249c06db181b274a55a69gstein<a href="/ja/mod/mpm_common.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
cccd31fa4a72fe23cc3249c06db181b274a55a69gstein<a href="/tr/mod/mpm_common.html" hreflang="tr" rel="alternate" title="T�rk�e">&nbsp;tr&nbsp;</a></p>
cccd31fa4a72fe23cc3249c06db181b274a55a69gstein</div>
cccd31fa4a72fe23cc3249c06db181b274a55a69gstein<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>A collection of directives that are implemented by
f4c310fd2555c6faca1f980f00b161eadb089023gsteinmore than one multi-processing module (MPM)</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="module-dict.html#Status">Status:</a></th><td>MPM</td></tr></table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div id="quickview"><h3 class="directives">Directives</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<ul id="toc">
1a9d922232824a7cc008d4f74e48bd82adf5bdedgstein<li><img alt="" src="/images/down.gif" /> <a href="#coredumpdirectory">CoreDumpDirectory</a></li>
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein<li><img alt="" src="/images/down.gif" /> <a href="#enableexceptionhook">EnableExceptionHook</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#gracefulshutdowntimeout">GracefulShutdownTimeout</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#listen">Listen</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#listenbacklog">ListenBackLog</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#maxclients">MaxClients</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#maxmemfree">MaxMemFree</a></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><img alt="" src="/images/down.gif" /> <a href="#maxrequestsperchild">MaxRequestsPerChild</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#maxsparethreads">MaxSpareThreads</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#minsparethreads">MinSpareThreads</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#pidfile">PidFile</a></li>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<li><img alt="" src="/images/down.gif" /> <a href="#receivebuffersize">ReceiveBufferSize</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#scoreboardfile">ScoreBoardFile</a></li>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<li><img alt="" src="/images/down.gif" /> <a href="#sendbuffersize">SendBufferSize</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#serverlimit">ServerLimit</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#startservers">StartServers</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#startthreads">StartThreads</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><img alt="" src="/images/down.gif" /> <a href="#threadlimit">ThreadLimit</a></li>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein<li><img alt="" src="/images/down.gif" /> <a href="#threadsperchild">ThreadsPerChild</a></li>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein<li><img alt="" src="/images/down.gif" /> <a href="#threadstacksize">ThreadStackSize</a></li>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein</ul>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein</div>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="CoreDumpDirectory" id="CoreDumpDirectory">CoreDumpDirectory</a> <a name="coredumpdirectory" id="coredumpdirectory">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Directory where Apache attempts to
707ecf9559338ec06b24334bc9abcca670325cc4gsteinswitch before dumping core</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>CoreDumpDirectory <var>directory</var></code></td></tr>
707ecf9559338ec06b24334bc9abcca670325cc4gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for the default setting</code></td></tr>
707ecf9559338ec06b24334bc9abcca670325cc4gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
707ecf9559338ec06b24334bc9abcca670325cc4gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
707ecf9559338ec06b24334bc9abcca670325cc4gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
52c1d304b1bd8e05da40a7cded2ecb9f0ba614c5gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>This controls the directory to which Apache attempts to
f4c310fd2555c6faca1f980f00b161eadb089023gstein switch before dumping core. If your operating system is configured to
f4c310fd2555c6faca1f980f00b161eadb089023gstein create core files in the working directory of the crashing process,
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive">CoreDumpDirectory</code> is necessary to change working
707ecf9559338ec06b24334bc9abcca670325cc4gstein directory from the default <code class="directive"><a href="/mod/core.html#serverroot">ServerRoot</a></code>
707ecf9559338ec06b24334bc9abcca670325cc4gstein directory, which should not be writable by the user the server runs as.</p>
707ecf9559338ec06b24334bc9abcca670325cc4gstein
707ecf9559338ec06b24334bc9abcca670325cc4gstein <p>If you want a core dump for debugging, you can use this directive to
707ecf9559338ec06b24334bc9abcca670325cc4gstein place it in a different location. This directive has no effect if your
707ecf9559338ec06b24334bc9abcca670325cc4gstein operating system is not configured to write core files to the working directory
707ecf9559338ec06b24334bc9abcca670325cc4gstein of the crashing processes.</p>
707ecf9559338ec06b24334bc9abcca670325cc4gstein
707ecf9559338ec06b24334bc9abcca670325cc4gstein <div class="note"><h3>Core Dumps on Linux</h3>
707ecf9559338ec06b24334bc9abcca670325cc4gstein <p>If Apache starts as root and switches to another user, the
707ecf9559338ec06b24334bc9abcca670325cc4gstein Linux kernel <em>disables</em> core dumps even if the directory is
707ecf9559338ec06b24334bc9abcca670325cc4gstein writable for the process. Apache (2.0.46 and later) reenables core dumps
707ecf9559338ec06b24334bc9abcca670325cc4gstein on Linux 2.4 and beyond, but only if you explicitly configure a <code class="directive">CoreDumpDirectory</code>.</p>
707ecf9559338ec06b24334bc9abcca670325cc4gstein </div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
707ecf9559338ec06b24334bc9abcca670325cc4gstein <div class="note"><h3>Specific signals</h3>
707ecf9559338ec06b24334bc9abcca670325cc4gstein <p><code class="directive">CoreDumpDirectory</code> processing only occurs for
707ecf9559338ec06b24334bc9abcca670325cc4gstein a select set of fatal signals: SIGFPE, SIGILL, SIGABORT,
707ecf9559338ec06b24334bc9abcca670325cc4gstein SIGSEGV, and SIGBUS.</p>
707ecf9559338ec06b24334bc9abcca670325cc4gstein <p>On some operating systems, SIGQUIT also results in a core dump but
707ecf9559338ec06b24334bc9abcca670325cc4gstein does not go through <code class="directive">CoreDumpDirectory</code> or
707ecf9559338ec06b24334bc9abcca670325cc4gstein <code class="directive">EnableExceptionHook</code> processing, so the core
f4c310fd2555c6faca1f980f00b161eadb089023gstein location is dictated entirely by the operating system.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein </div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="EnableExceptionHook" id="EnableExceptionHook">EnableExceptionHook</a> <a name="enableexceptionhook" id="enableexceptionhook">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enables a hook that runs exception handlers
f4c310fd2555c6faca1f980f00b161eadb089023gsteinafter a crash</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnableExceptionHook On|Off</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnableExceptionHook Off</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.0.49 and later</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>For safety reasons this directive is only available if the server was
f4c310fd2555c6faca1f980f00b161eadb089023gstein configured with the <code>--enable-exception-hook</code> option. It
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe enables a hook that allows external modules to plug in and do something
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe after a child crashed.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>There are already two modules, <code>mod_whatkilledus</code> and
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein <code>mod_backtrace</code> that make use of this hook. Please have a
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein look at Jeff Trawick's <a href="http://www.apache.org/~trawick/exception_hook.html">EnableExceptionHook site</a> for more information about these.</p>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein</div>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein<div class="directive-section"><h2><a name="GracefulShutdownTimeout" id="GracefulShutdownTimeout">GracefulShutdownTimeout</a> <a name="gracefulshutdowntimeout" id="gracefulshutdowntimeout">Directive</a></h2>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein<table class="directive">
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Specify a timeout after which a gracefully shutdown server
0b1895a2cd5b4a9450709abdb7ae9974908f9382gsteinwill exit.</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>GracefulShutDownTimeout <var>seconds</var></code></td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>GracefulShutDownTimeout 0</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code>, <code class="module"><a href="/mod/event.html">event</a></code></td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in version 2.2 and later</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein <p>The <code class="directive">GracefulShutdownTimeout</code> specifies
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein how many seconds after receiving a "graceful-stop" signal, a
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein server should continue to run, handling the existing connections.</p>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein <p>Setting this value to zero means that the server will wait
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein indefinitely until all remaining requests have been fully served.</p>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein</div>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<div class="directive-section"><h2><a name="Listen" id="Listen">Listen</a> <a name="listen" id="listen">Directive</a></h2>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<table class="directive">
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>IP addresses and ports that the server
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gsteinlistens to</td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Listen [<var>IP-address</var>:]<var>portnumber</var> [<var>protocol</var>]</code></td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code>, <code class="module"><a href="/mod/event.html">event</a></code></td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Required directive since Apache 2.0<br />
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gsteinThe <var>protocol</var> argument was added in 2.1.5</td></tr>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein</table>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein <p>The <code class="directive">Listen</code> directive instructs Apache to
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein listen to only specific IP addresses or ports; by default it
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein responds to requests on all IP interfaces. <code class="directive">Listen</code>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein is now a required directive. If it is not in the config file, the
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein server will fail to start. This is a change from previous versions
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein of Apache.</p>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein <p>The <code class="directive">Listen</code> directive tells the server to
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein accept incoming requests on the specified port or address-and-port
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein combination. If only a port number is specified, the server listens to
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein the given port on all interfaces. If an IP address is given as well
956f4b1551215610a57f3b52822dbac6f41a8aa9gstein as a port, the server will listen on the given port and
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein interface.</p>
0b1895a2cd5b4a9450709abdb7ae9974908f9382gstein
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>Multiple <code class="directive">Listen</code> directives may be used to
f4c310fd2555c6faca1f980f00b161eadb089023gstein specify a number of addresses and ports to listen to. The server will
f4c310fd2555c6faca1f980f00b161eadb089023gstein respond to requests from any of the listed addresses and ports.</p>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein <p>For example, to make the server accept connections on both
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein port 80 and port 8000, use:</p>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein <div class="example"><p><code>
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein Listen 80<br />
0e8fe062a6ec71b4207d1a125ee6b44b7fd30857gstein Listen 8000
f4c310fd2555c6faca1f980f00b161eadb089023gstein </code></p></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>To make the server accept connections on two specified
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm interfaces and port numbers, use </p>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <div class="example"><p><code>
f4c310fd2555c6faca1f980f00b161eadb089023gstein Listen 192.170.2.1:80<br />
f4c310fd2555c6faca1f980f00b161eadb089023gstein Listen 192.170.2.5:8000
e8f95a682820a599fe41b22977010636be5c2717jim </code></p></div>
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton <p>IPv6 addresses must be surrounded in square brackets, as in the
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton following example:</p>
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="example"><p><code>
f94aab38f6ee899f463f0118ea395291f7c5b4cegstein Listen [2001:db8::a00:20ff:fea7:ccea]:80
f94aab38f6ee899f463f0118ea395291f7c5b4cegstein </code></p></div>
707ecf9559338ec06b24334bc9abcca670325cc4gstein
707ecf9559338ec06b24334bc9abcca670325cc4gstein <p>The optional <var>protocol</var> argument is not required for most
707ecf9559338ec06b24334bc9abcca670325cc4gstein configurations. If not specified, <code>https</code> is the default for
707ecf9559338ec06b24334bc9abcca670325cc4gstein port 443 and <code>http</code> the default for all other ports. The
f4c310fd2555c6faca1f980f00b161eadb089023gstein protocol is used to determine which module should handle a request, and
f4c310fd2555c6faca1f980f00b161eadb089023gstein to apply protocol specific optimizations with the
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive"><a href="/mod/core.html#acceptfilter">AcceptFilter</a></code> directive.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>You only need to set the protocol if you are running on non-standard
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm ports. For example, running an <code>https</code> site on port 8443:</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="example"><p><code>
f4c310fd2555c6faca1f980f00b161eadb089023gstein Listen 192.170.2.1:8443 https
f4c310fd2555c6faca1f980f00b161eadb089023gstein </code></p></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="note"><h3>Error condition</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein Multiple <code class="directive">Listen</code> directives for the same ip
f4c310fd2555c6faca1f980f00b161eadb089023gstein address and port will result in an <code>Address already in use</code>
f4c310fd2555c6faca1f980f00b161eadb089023gstein error message.
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein </div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein<h3>See also</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><a href="/dns-caveats.html">DNS Issues</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><a href="/bind.html">Setting which addresses and ports Apache
f4c310fd2555c6faca1f980f00b161eadb089023gstein uses</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><a href="http://wiki.apache.org/httpd/CouldNotBindToAddress">Further
f4c310fd2555c6faca1f980f00b161eadb089023gsteindiscussion of the <code>Address already in use</code> error message,
f4c310fd2555c6faca1f980f00b161eadb089023gsteinincluding other causes.</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="ListenBackLog" id="ListenBackLog">ListenBackLog</a> <a name="listenbacklog" id="listenbacklog">Directive</a></h2>
49bf4df23d9e5281abcd83005550bda818b17b08wrowe<table class="directive">
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Maximum length of the queue of pending connections</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ListenBacklog <var>backlog</var></code></td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ListenBacklog 511</code></td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
e8f95a682820a599fe41b22977010636be5c2717jim</table>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe <p>The maximum length of the queue of pending connections.
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe Generally no tuning is needed or desired, however on some
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe systems it is desirable to increase this when under a TCP SYN
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe flood attack. See the backlog parameter to the
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe <code>listen(2)</code> system call.</p>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe <p>This will often be limited to a smaller number by the
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe operating system. This varies from OS to OS. Also note that
e8f95a682820a599fe41b22977010636be5c2717jim many OSes do not use exactly what is specified as the backlog,
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe but use a number based on (but normally larger than) what is
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe set.</p>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe</div>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<div class="directive-section"><h2><a name="MaxClients" id="MaxClients">MaxClients</a> <a name="maxclients" id="maxclients">Directive</a></h2>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<table class="directive">
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Maximum number of connections that will be processed
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowesimultaneously</td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxClients <var>number</var></code></td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe</table>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe <p>The <code class="directive">MaxClients</code> directive sets the limit
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein on the number of simultaneous requests that will be served. Any
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein connection attempts over the <code class="directive">MaxClients</code>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein limit will normally be queued, up to a number based on the
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive"><a href="#listenbacklog">ListenBacklog</a></code>
f4c310fd2555c6faca1f980f00b161eadb089023gstein directive. Once a child process is freed at the end of a different
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein request, the connection will then be serviced.</p>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>For non-threaded servers (<em>i.e.</em>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>),
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive">MaxClients</code> translates into the maximum
f4c310fd2555c6faca1f980f00b161eadb089023gstein number of child processes that will be launched to serve requests.
f4c310fd2555c6faca1f980f00b161eadb089023gstein The default value is <code>256</code>; to increase it, you must also raise
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm <code class="directive"><a href="#serverlimit">ServerLimit</a></code>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
01e8aca9299a0b872414c24c8b7724d6f88ae665ianh <p>For threaded and hybrid servers (<em>e.g.</em> <code class="module"><a href="/mod/event.html">event</a></code>
e8f95a682820a599fe41b22977010636be5c2717jim or <code class="module"><a href="/mod/worker.html">worker</a></code>) <code class="directive">MaxClients</code> restricts
f71d4ec448449837beefe21cf7c9f8d9b6bd4654gstein the total number of threads that will be available to serve clients.
93ef028b3ac7dc86ec72204233b9d99c69587c54striker For hybrid MPMs the default value is <code>16</code> (<code class="directive"><a href="#serverlimit">ServerLimit</a></code>) multiplied by the value of
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code>25</code> (<code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code>). Therefore, to increase <code class="directive">MaxClients</code> to a value that requires more than 16 processes,
f4c310fd2555c6faca1f980f00b161eadb089023gstein you must also raise <code class="directive"><a href="#serverlimit">ServerLimit</a></code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="directive-section"><h2><a name="MaxMemFree" id="MaxMemFree">MaxMemFree</a> <a name="maxmemfree" id="maxmemfree">Directive</a></h2>
f71d4ec448449837beefe21cf7c9f8d9b6bd4654gstein<table class="directive">
f71d4ec448449837beefe21cf7c9f8d9b6bd4654gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Maximum amount of memory that the main allocator is allowed
f4c310fd2555c6faca1f980f00b161eadb089023gsteinto hold without calling <code>free()</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxMemFree <var>KBytes</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>MaxMemFree 0</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>The <code class="directive">MaxMemFree</code> directive sets the
10a4cdd68ef1ca0e54af296fe1d08ac00150c90bwrowe maximum number of free Kbytes that the main allocator is allowed
10a4cdd68ef1ca0e54af296fe1d08ac00150c90bwrowe to hold without calling <code>free()</code>. When not set, or when set
f71d4ec448449837beefe21cf7c9f8d9b6bd4654gstein to zero, the threshold will be set to unlimited.</p>
f71d4ec448449837beefe21cf7c9f8d9b6bd4654gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<div class="directive-section"><h2><a name="MaxRequestsPerChild" id="MaxRequestsPerChild">MaxRequestsPerChild</a> <a name="maxrequestsperchild" id="maxrequestsperchild">Directive</a></h2>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<table class="directive">
7f69a90d847f08a86f9909c2c5129408697a9600jorton<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Limit on the number of requests that an individual child server
f4c310fd2555c6faca1f980f00b161eadb089023gsteinwill handle during its life</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxRequestsPerChild <var>number</var></code></td></tr>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>MaxRequestsPerChild 10000</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
7f69a90d847f08a86f9909c2c5129408697a9600jorton</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The <code class="directive">MaxRequestsPerChild</code> directive sets
f4c310fd2555c6faca1f980f00b161eadb089023gstein the limit on the number of requests that an individual child
f4c310fd2555c6faca1f980f00b161eadb089023gstein server process will handle. After
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm <code class="directive">MaxRequestsPerChild</code> requests, the child
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm process will die. If <code class="directive">MaxRequestsPerChild</code> is
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton <code>0</code>, then the process will never expire.</p>
7f69a90d847f08a86f9909c2c5129408697a9600jorton
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="note"><h3>Different default values</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The default value for <code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code> and
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code> is <code>0</code>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein </div>
7f69a90d847f08a86f9909c2c5129408697a9600jorton
7f69a90d847f08a86f9909c2c5129408697a9600jorton <p>Setting <code class="directive">MaxRequestsPerChild</code> to a
7f69a90d847f08a86f9909c2c5129408697a9600jorton non-zero value limits the amount of memory that process can consume
ebf7895684796436b808025426cbfab96d57910dnd by (accidental) memory leakage.</p>
ebf7895684796436b808025426cbfab96d57910dnd
7f69a90d847f08a86f9909c2c5129408697a9600jorton <div class="note"><h3>Note</h3>
7f69a90d847f08a86f9909c2c5129408697a9600jorton <p>For <code class="directive"><a href="/mod/core.html#keepalive">KeepAlive</a></code> requests, only
ebf7895684796436b808025426cbfab96d57910dnd the first request is counted towards this limit. In effect, it
7f69a90d847f08a86f9909c2c5129408697a9600jorton changes the behavior to limit the number of <em>connections</em> per
7f69a90d847f08a86f9909c2c5129408697a9600jorton child.</p>
7f69a90d847f08a86f9909c2c5129408697a9600jorton </div>
7f69a90d847f08a86f9909c2c5129408697a9600jorton
e8f95a682820a599fe41b22977010636be5c2717jim</div>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<div class="directive-section"><h2><a name="MaxSpareThreads" id="MaxSpareThreads">MaxSpareThreads</a> <a name="maxsparethreads" id="maxsparethreads">Directive</a></h2>
7f69a90d847f08a86f9909c2c5129408697a9600jorton<table class="directive">
7f69a90d847f08a86f9909c2c5129408697a9600jorton<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Maximum number of idle threads</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MaxSpareThreads <var>number</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
e8f95a682820a599fe41b22977010636be5c2717jim<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>Maximum number of idle threads. Different MPMs deal with this
f4c310fd2555c6faca1f980f00b161eadb089023gstein directive differently.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>For <code class="module"><a href="/mod/worker.html">worker</a></code>, the default is
e8f95a682820a599fe41b22977010636be5c2717jim <code>MaxSpareThreads 250</code>. This MPM deals with idle threads
7f69a90d847f08a86f9909c2c5129408697a9600jorton on a server-wide basis. If there are too many idle threads in the
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton server then child processes are killed until the number of idle
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe threads is less than this number.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton <p>For <code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code> the default is
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code>MaxSpareThreads 100</code>. Since this MPM runs a
f4c310fd2555c6faca1f980f00b161eadb089023gstein single-process, the spare thread count is also server-wide.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p><code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code> works
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe similar to <code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>. For
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code> the default value is <code>10</code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <div class="note"><h3>Restrictions</h3>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>The range of the <code class="directive">MaxSpareThreads</code> value
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe is restricted. Apache will correct the given value automatically
e8f95a682820a599fe41b22977010636be5c2717jim according to the following rules:</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <li><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code> wants the value to be greater than
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="directive"><a href="#minsparethreads">MinSpareThreads</a></code>.</li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <li>For <code class="module"><a href="/mod/worker.html">worker</a></code>, the value must be greater or equal
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe to the sum of <code class="directive"><a href="#minsparethreads">MinSpareThreads</a></code>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe and <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code>.</li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe </ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe </div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<h3>See also</h3>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="#minsparethreads">MinSpareThreads</a></code></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="#startservers">StartServers</a></code></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><code class="directive"><a href="/mod/prefork.html#maxspareservers">MaxSpareServers</a></code></li>
7ac747af0cf476c2276aaf9999425e1b52bf5f64jorton</ul>
7ac747af0cf476c2276aaf9999425e1b52bf5f64jorton</div>
7ac747af0cf476c2276aaf9999425e1b52bf5f64jorton<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
7ac747af0cf476c2276aaf9999425e1b52bf5f64jorton<div class="directive-section"><h2><a name="MinSpareThreads" id="MinSpareThreads">MinSpareThreads</a> <a name="minsparethreads" id="minsparethreads">Directive</a></h2>
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton<table class="directive">
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Minimum number of idle threads available to handle request
6f15570e3adc0faf87bf55f70857028276fc9e32wrowespikes</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>MinSpareThreads <var>number</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>Minimum number of idle threads to handle request spikes.
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe Different MPMs deal with this directive
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe differently.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p><code class="module"><a href="/mod/worker.html">worker</a></code> uses a default of <code>MinSpareThreads
f4c310fd2555c6faca1f980f00b161eadb089023gstein 75</code> and deals with idle threads on a server-wide basis. If
9ec6440fdeb81f04905959293b381ebbfa3114c2jorton there aren't enough idle threads in the server then child
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe processes are created until the number of idle threads is greater
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe than <var>number</var>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code> uses a default of
066877f1a045103acfdd376d48cdd473c33f409bdougm <code>MinSpareThreads 10</code> and, since it is a single-process
066877f1a045103acfdd376d48cdd473c33f409bdougm MPM, tracks this on a server-wide bases.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
da9adab0554faf94f8cc2705c2363aceacf75c46gstein <p><code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code> works
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe similar to <code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>. For
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code> the default value is <code>5</code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<h3>See also</h3>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="#maxsparethreads">MaxSpareThreads</a></code></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="#startservers">StartServers</a></code></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="/mod/prefork.html#minspareservers">MinSpareServers</a></code></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="directive-section"><h2><a name="PidFile" id="PidFile">PidFile</a> <a name="pidfile" id="pidfile">Directive</a></h2>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>File where the server records the process ID
6f15570e3adc0faf87bf55f70857028276fc9e32wroweof the daemon</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>PidFile <var>filename</var></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>PidFile logs/httpd.pid</code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The <code class="directive">PidFile</code> directive sets the file to
f4c310fd2555c6faca1f980f00b161eadb089023gstein which the server records the process id of the daemon. If the
f4c310fd2555c6faca1f980f00b161eadb089023gstein filename is not absolute then it is assumed to be relative to the
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive"><a href="/mod/core.html#serverroot">ServerRoot</a></code>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="example"><h3>Example</h3><p><code>
f4c310fd2555c6faca1f980f00b161eadb089023gstein PidFile /var/run/apache.pid
f4c310fd2555c6faca1f980f00b161eadb089023gstein </code></p></div>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>It is often useful to be able to send the server a signal,
f4c310fd2555c6faca1f980f00b161eadb089023gstein so that it closes and then re-opens its <code class="directive"><a href="/mod/core.html#errorlog">ErrorLog</a></code> and <code class="directive"><a href="/mod/mod_log_config.html#transferlog">TransferLog</a></code>, and
f4c310fd2555c6faca1f980f00b161eadb089023gstein re-reads its configuration files. This is done by sending a
f4c310fd2555c6faca1f980f00b161eadb089023gstein SIGHUP (kill -1) signal to the process id listed in the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="directive">PidFile</code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
4c449c30215bd5e8bad122a4118f5a7b0e995472wrowe <p>The <code class="directive">PidFile</code> is subject to the same
f4c310fd2555c6faca1f980f00b161eadb089023gstein warnings about log file placement and <a href="/misc/security_tips.html#serverroot">security</a>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="note"><h3>Note</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>As of Apache 2, we recommended that you only use the <code class="program"><a href="/programs/apachectl.html">apachectl</a></code> script, or the init script that your OS provides,
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm for (re-)starting or stopping the server.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein </div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe</div>
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="directive-section"><h2><a name="ReceiveBufferSize" id="ReceiveBufferSize">ReceiveBufferSize</a> <a name="receivebuffersize" id="receivebuffersize">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>TCP receive buffer size</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ReceiveBufferSize <var>bytes</var></code></td></tr>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ReceiveBufferSize 0</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
066877f1a045103acfdd376d48cdd473c33f409bdougm <p>The server will set the TCP receive buffer size to the number of
4c449c30215bd5e8bad122a4118f5a7b0e995472wrowe bytes specified.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>If set to the value of <code>0</code>, the server will use the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe OS default.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="ScoreBoardFile" id="ScoreBoardFile">ScoreBoardFile</a> <a name="scoreboardfile" id="scoreboardfile">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowe<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Location of the file used to store coordination data for
2f40d5ac42ba2e7a8043eca56b5f5d8dce101f94wrowethe child processes</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ScoreBoardFile <var>file-path</var></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ScoreBoardFile logs/apache_status</code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>Apache uses a scoreboard to communicate between its parent
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein and child processes. Some architectures require a file to facilitate
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe this communication. If the file is left unspecified, Apache first
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe attempts to create the scoreboard entirely in memory (using anonymous
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe shared memory) and, failing that, will attempt to create the file on
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe disk (using file-based shared memory). Specifying this directive causes
f4c310fd2555c6faca1f980f00b161eadb089023gstein Apache to always create the file on the disk.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="example"><h3>Example</h3><p><code>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm ScoreBoardFile /var/run/apache_status
f4c310fd2555c6faca1f980f00b161eadb089023gstein </code></p></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
5646ba89a25a695006edae46de226fb57a2e6270gstein <p>File-based shared memory is useful for third-party applications
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe that require direct access to the scoreboard.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>If you use a <code class="directive">ScoreBoardFile</code> then
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe you may see improved speed by placing it on a RAM disk. But be
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe careful that you heed the same warnings about log file placement
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe and <a href="/misc/security_tips.html">security</a>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein<h3>See also</h3>
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein<ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><a href="/stopping.html">Stopping and Restarting
7f69a90d847f08a86f9909c2c5129408697a9600jortonApache</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="SendBufferSize" id="SendBufferSize">SendBufferSize</a> <a name="sendbuffersize" id="sendbuffersize">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>TCP buffer size</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>SendBufferSize <var>bytes</var></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>SendBufferSize 0</code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>Sets the server's TCP send buffer size to the number of bytes
f4c310fd2555c6faca1f980f00b161eadb089023gstein specified. It is often useful to set this past the OS's standard
f4c310fd2555c6faca1f980f00b161eadb089023gstein default value on high speed, high latency conections
f4c310fd2555c6faca1f980f00b161eadb089023gstein (<em>i.e.</em>, 100ms or so, such as transcontinental fast pipes).</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>If set to the value of <code>0</code>, the server will use the
f4c310fd2555c6faca1f980f00b161eadb089023gstein default value provided by your OS.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein<div class="directive-section"><h2><a name="ServerLimit" id="ServerLimit">ServerLimit</a> <a name="serverlimit" id="serverlimit">Directive</a></h2>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Upper limit on configurable number of processes</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ServerLimit <var>number</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>For the <code class="module"><a href="/mod/prefork.html">prefork</a></code> MPM, this directive sets the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe maximum configured value for <code class="directive"><a href="#maxclients">MaxClients</a></code> for the lifetime of the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe Apache process. For the <code class="module"><a href="/mod/worker.html">worker</a></code> MPM, this directive
f4c310fd2555c6faca1f980f00b161eadb089023gstein in combination with <code class="directive"><a href="#threadlimit">ThreadLimit</a></code> sets
f4c310fd2555c6faca1f980f00b161eadb089023gstein the maximum configured value for <code class="directive"><a href="#maxclients">MaxClients</a></code> for the lifetime of the
f4c310fd2555c6faca1f980f00b161eadb089023gstein Apache process. Any attempts to change this directive during a
f4c310fd2555c6faca1f980f00b161eadb089023gstein restart will be ignored, but <code class="directive"><a href="#maxclients">MaxClients</a></code> can be modified during
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe a restart.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>Special care must be taken when using this directive. If
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive">ServerLimit</code> is set to a value much higher
f4c310fd2555c6faca1f980f00b161eadb089023gstein than necessary, extra, unused shared memory will be allocated. If
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe both <code class="directive">ServerLimit</code> and <code class="directive"><a href="#maxclients">MaxClients</a></code> are set to values
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe higher than the system can handle, Apache may not start or the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe system may become unstable.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>With the <code class="module"><a href="/mod/prefork.html">prefork</a></code> MPM, use this directive only
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe if you need to set <code class="directive"><a href="#maxclients">MaxClients</a></code> higher than 256 (default).
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe Do not set the value of this directive any higher than what you
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe might want to set <code class="directive"><a href="#maxclients">MaxClients</a></code> to.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>With <code class="module"><a href="/mod/worker.html">worker</a></code>, use this directive only
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe if your <code class="directive"><a href="#maxclients">MaxClients</a></code> and
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe settings require more than 16 server processes (default). Do not set
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe the value of this directive any higher than the number of server
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe processes required by what you may want for <code class="directive"><a href="#maxclients ">MaxClients </a></code> and <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="note"><h3>Note</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>There is a hard limit of <code>ServerLimit 20000</code> compiled
f4c310fd2555c6faca1f980f00b161eadb089023gstein into the server (for the <code class="module"><a href="/mod/prefork.html">prefork</a></code> MPM 200000). This is
f4c310fd2555c6faca1f980f00b161eadb089023gstein intended to avoid nasty effects caused by typos.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein </div>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm
f4c310fd2555c6faca1f980f00b161eadb089023gstein<h3>See also</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><a href="/stopping.html">Stopping and Restarting Apache</a></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
da9adab0554faf94f8cc2705c2363aceacf75c46gstein<div class="directive-section"><h2><a name="StartServers" id="StartServers">StartServers</a> <a name="startservers" id="startservers">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Number of child server processes created at startup</td></tr>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>StartServers <var>number</var></code></td></tr>
cc8241a7ee9815575a267e13eff62b6fddf1fe58gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code>, <code class="module"><a href="/mod/prefork.html">prefork</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>The <code class="directive">StartServers</code> directive sets the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe number of child server processes created on startup. As the number
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe of processes is dynamically controlled depending on the load,
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe there is usually little reason to adjust this parameter.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The default value differs from MPM to MPM. <code class="module"><a href="/mod/worker.html">worker</a></code>
da9adab0554faf94f8cc2705c2363aceacf75c46gstein defaults to <code>StartServers 3</code>; <code class="module"><a href="/mod/prefork.html">prefork</a></code>
da9adab0554faf94f8cc2705c2363aceacf75c46gstein defaults to <code>5</code>; <code class="module"><a href="/mod/mpmt_os2.html">mpmt_os2</a></code> defaults to
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code>2</code>.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="StartThreads" id="StartThreads">StartThreads</a> <a name="startthreads" id="startthreads">Directive</a></h2>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<table class="directive">
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Number of threads created on startup</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>StartThreads <var>number</var></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code></td></tr>
da9adab0554faf94f8cc2705c2363aceacf75c46gstein</table>
da9adab0554faf94f8cc2705c2363aceacf75c46gstein <p>Number of threads created on startup. As the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe number of threads is dynamically controlled depending on the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe load, there is usually little reason to adjust this
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe parameter.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>For <code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code> the default is
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code>StartThreads 50</code> and, since there is only a single
f4c310fd2555c6faca1f980f00b161eadb089023gstein process, this is the total number of threads created at startup to
f4c310fd2555c6faca1f980f00b161eadb089023gstein serve requests.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="ThreadLimit" id="ThreadLimit">ThreadLimit</a> <a name="threadlimit" id="threadlimit">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Sets the upper limit on the configurable number of threads
f4c310fd2555c6faca1f980f00b161eadb089023gsteinper child process</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ThreadLimit <var>number</var></code></td></tr>
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f39230a531b23d94f86a087963299bbe2e431a4agstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f39230a531b23d94f86a087963299bbe2e431a4agstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available for <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code> in Apache 2.0.41
866b521be8a30b2798ad3c3b73de5e965edd7c2fgsteinand later</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>This directive sets the maximum configured value for <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code> for the lifetime
f4c310fd2555c6faca1f980f00b161eadb089023gstein of the Apache process. Any attempts to change this directive
f4c310fd2555c6faca1f980f00b161eadb089023gstein during a restart will be ignored, but <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code> can be modified
f4c310fd2555c6faca1f980f00b161eadb089023gstein during a restart up to the value of this directive.</p>
49bf4df23d9e5281abcd83005550bda818b17b08wrowe
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>Special care must be taken when using this directive. If
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code class="directive">ThreadLimit</code> is set to a value much higher
f4c310fd2555c6faca1f980f00b161eadb089023gstein than <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code>,
f4c310fd2555c6faca1f980f00b161eadb089023gstein extra unused shared memory will be allocated. If both
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm <code class="directive">ThreadLimit</code> and <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code> are set to values
f4c310fd2555c6faca1f980f00b161eadb089023gstein higher than the system can handle, Apache may not start or the
f4c310fd2555c6faca1f980f00b161eadb089023gstein system may become unstable. Do not set the value of this directive
ba2ad3b1bb4a729278ad8e8846d34ddd27b6551cgstein any higher than your greatest predicted setting of <code class="directive"><a href="#threadsperchild">ThreadsPerChild</a></code> for the
ba2ad3b1bb4a729278ad8e8846d34ddd27b6551cgstein current run of Apache.</p>
ba2ad3b1bb4a729278ad8e8846d34ddd27b6551cgstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The default value for <code class="directive">ThreadLimit</code> is
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein <code>1920</code> when used with <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code> and
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein <code>64</code> when used with the others.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <div class="note"><h3>Note</h3>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>There is a hard limit of <code>ThreadLimit 20000</code> (or
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code>ThreadLimit 15000</code> with <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>)
f4c310fd2555c6faca1f980f00b161eadb089023gstein compiled into the server. This is intended to avoid nasty effects
f4c310fd2555c6faca1f980f00b161eadb089023gstein caused by typos.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein </div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="ThreadsPerChild" id="ThreadsPerChild">ThreadsPerChild</a> <a name="threadsperchild" id="threadsperchild">Directive</a></h2>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Number of threads created by each child process</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ThreadsPerChild <var>number</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>See usage for details</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>This directive sets the number of threads created by each
f4c310fd2555c6faca1f980f00b161eadb089023gstein child process. The child creates these threads at startup and
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm never creates more. If using an MPM like <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>,
f4c310fd2555c6faca1f980f00b161eadb089023gstein where there is only one child process, this number should be high
f4c310fd2555c6faca1f980f00b161eadb089023gstein enough to handle the entire load of the server. If using an MPM
f4c310fd2555c6faca1f980f00b161eadb089023gstein like <code class="module"><a href="/mod/worker.html">worker</a></code>, where there are multiple child processes,
ba2ad3b1bb4a729278ad8e8846d34ddd27b6551cgstein the <em>total</em> number of threads should be high enough to handle
f4c310fd2555c6faca1f980f00b161eadb089023gstein the common load on the server.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The default value for <code class="directive">ThreadsPerChild</code> is
f4c310fd2555c6faca1f980f00b161eadb089023gstein <code>64</code> when used with <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code> and
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <code>25</code> when used with the others.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="ThreadStackSize" id="ThreadStackSize">ThreadStackSize</a> <a name="threadstacksize" id="threadstacksize">Directive</a></h2>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<table class="directive">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>The size in bytes of the stack used by threads handling
f4c310fd2555c6faca1f980f00b161eadb089023gsteinclient connections</td></tr>
f54da7877f9e092465df38bfda142f3e71dbb7aawrowe<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ThreadStackSize <var>size</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>65536 on NetWare; varies on other operating systems</code></td></tr>
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>MPM</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mpm_netware.html">mpm_netware</a></code>, <code class="module"><a href="/mod/mpm_winnt.html">mpm_winnt</a></code>, <code class="module"><a href="/mod/worker.html">worker</a></code></td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache 2.1 and later</td></tr>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe</table>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>The <code class="directive">ThreadStackSize</code> directive sets the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe size of the stack (for autodata) of threads which handle client
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe connections and call modules to help process those connections.
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe In most cases the operating system default for stack size is
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe reasonable, but there are some conditions where it may need to be
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe adjusted:</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <ul>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <li>On platforms with a relatively small default thread stack size
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe (e.g., HP-UX), Apache may crash when using some third-party modules
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe which use a relatively large amount of autodata storage. Those
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe same modules may have worked fine on other platforms where the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe default thread stack size is larger. This type of crash is
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe resolved by setting <code class="directive">ThreadStackSize</code> to a
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe value higher than the operating system default. This type of
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe adjustment is necessary only if the provider of the third-party
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe module specifies that it is required, or if diagnosis of an Apache
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe crash indicates that the thread stack size was too small.</li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein <li>On platforms where the default thread stack size is
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein significantly larger than necessary for the web server
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein configuration, a higher number of threads per child process
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein will be achievable if <code class="directive">ThreadStackSize</code> is
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe set to a value lower than the operating system default. This type
f4c310fd2555c6faca1f980f00b161eadb089023gstein of adjustment should only be made in a test environment which allows
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe the full set of web server processing can be exercised, as there
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe may be infrequent requests which require more stack to process.
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe A change in the web server configuration can invalidate the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe current <code class="directive">ThreadStackSize</code> setting.</li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe </ul>
f4c310fd2555c6faca1f980f00b161eadb089023gstein
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div>
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein</div>
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein<div class="bottomlang">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p><span>Available Languages: </span><a href="/de/mod/mpm_common.html" hreflang="de" rel="alternate" title="Deutsch">&nbsp;de&nbsp;</a> |
f4c310fd2555c6faca1f980f00b161eadb089023gstein<a href="/en/mod/mpm_common.html" title="English">&nbsp;en&nbsp;</a> |
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein<a href="/ja/mod/mpm_common.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
866b521be8a30b2798ad3c3b73de5e965edd7c2fgstein<a href="/tr/mod/mpm_common.html" hreflang="tr" rel="alternate" title="T�rk�e">&nbsp;tr&nbsp;</a></p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</div><div id="footer">
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p class="apache">Copyright 2010 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>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="/faq/">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein</body></html>