summaryrefslogtreecommitdiffstats
path: root/docs/manual/process-model.html
blob: 74f7d4e6eb487a56004967177ab2fb8ddcbad7d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML><HEAD>
<TITLE>Server Pool Management</TITLE>
</HEAD>

<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
<BODY
 BGCOLOR="#FFFFFF"
 TEXT="#000000"
 LINK="#0000FF"
 VLINK="#000080"
 ALINK="#FF0000"
>
<!--#include virtual="header.html" -->
<H1 ALIGN="CENTER">Server Pool Management</H1>

<HR>
<P>
We found that many people were using values for "MaxServers" either
too high or too low, and were hanging themselves on it.  The model we
adopted is still based on long-lived minimal-forking processes, but
instead of specifying one number of persistent processes, the
web-master specifies a maximum and minimum number of processes to be
"spare" - every couple of seconds the parent checks the actual number
of spare servers and adjusts accordingly.  This should keep the number
of servers concurrently running relatively low while still ensuring
minimal forking.

<P>

We renamed the current StartServers to MinSpareServers, created
separate StartServers parameter which means what it says, and renamed
MaxServers to MaxSpareServers (though the old name still works, for
NCSA 1.4 back-compatibility).  The old names were generally regarded
as too confusing.

<P>

The defaults for each variable are:

<PRE>
MinSpareServers         5
MaxSpareServers         10
StartServers            5
</PRE>

There is an absolute maximum number of simultaneous children defined
by a compile-time limit which defaults to 256 and a "MaxClients"
directive which specifies the number of simultaneous children that
will be allowed.  MaxClients can be adjusted up to the compile-time
limit (HARD_SERVER_LIMIT, defined in httpd.h).  If you need more
than 256 simultaneous children, you need to modify both HARD_SERVER_LIMIT
and MaxClients.<P>

In versions before 1.2, HARD_SERVER_LIMIT defaulted to 150.<P>

We do not recommend changing either of these values unless:

<OL>
<LI>You know you have the server resources to handle more
<LI>You use the machine for other purposes and must limit the amount of memory
Apache uses
</OL>

<!--#include virtual="footer.html" -->
</BODY></HTML>