core.html revision 7cc8575b89434b03a0b6e33047943f6562f50c55
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HTML>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HEAD>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<TITLE>Apache Core Features</TITLE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</HEAD>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BODY
25cf1a301a396c38e8adf52c15f537b80d2483f7jl BGCOLOR="#FFFFFF"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl TEXT="#000000"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl LINK="#0000FF"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl VLINK="#000080"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl ALINK="#FF0000"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--#include virtual="header.html" -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H1 ALIGN="CENTER">Apache Core Features</H1>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThese configuration parameters control the core Apache features, and are
25cf1a301a396c38e8adf52c15f537b80d2483f7jlalways available.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</P>
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson<H2>Directives</H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#accessconfig">AccessConfig</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#accessfilename">AccessFileName</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#addmodule">AddModule</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#allowoverride">AllowOverride</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#authname">AuthName</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#authtype">AuthType</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#bindaddress">BindAddress</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#bs2000account">BS2000Account</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#clearmodulelist">ClearModuleList</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#contentdigest">ContentDigest</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#coredumpdirectory">CoreDumpDirectory</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#defaulttype">DefaultType</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#directory">&lt;Directory&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#directorymatch">&lt;DirectoryMatch&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#documentroot">DocumentRoot</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#errordocument">ErrorDocument</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#errorlog">ErrorLog</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#files">&lt;Files&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#filesmatch">&lt;FilesMatch&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#group">Group</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#hostnamelookups">HostNameLookups</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#identitycheck">IdentityCheck</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#ifdefine">&lt;IfDefine&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#ifmodule">&lt;IfModule&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#include">Include</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#keepalive">KeepAlive</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#keepalivetimeout">KeepAliveTimeout</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limit">&lt;Limit&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limitexcept">&lt;LimitExcept&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limitrequestbody">LimitRequestBody</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limitrequestfields">LimitRequestFields</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limitrequestfieldsize">LimitRequestFieldsize</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#limitrequestline">LimitRequestLine</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#listen">Listen</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#listenbacklog">ListenBacklog</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#location">&lt;Location&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#locationmatch">&lt;LocationMatch&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#lockfile">LockFile</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#loglevel">LogLevel</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#maxclients">MaxClients</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#maxkeepaliverequests">MaxKeepAliveRequests</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#maxrequestsperchild">MaxRequestsPerChild</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#maxspareservers">MaxSpareServers</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#minspareservers">MinSpareServers</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#namevirtualhost">NameVirtualHost</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#options">Options</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#pidfile">PidFile</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#port">Port</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#require">require</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#resourceconfig">ResourceConfig</A>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<LI><A HREF="#rlimitcpu">RLimitCPU</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#rlimitmem">RLimitMEM</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#rlimitnproc">RLimitNPROC</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#satisfy">Satisfy</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#scoreboardfile">ScoreBoardFile</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#scriptinterpretersource">ScriptInterpreterSource</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#sendbuffersize">SendBufferSize</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#serveradmin">ServerAdmin</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#serveralias">ServerAlias</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#servername">ServerName</A>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<LI><A HREF="#serverpath">ServerPath</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#serverroot">ServerRoot</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#serversignature">ServerSignature</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#servertokens">ServerTokens</A>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<LI><A HREF="#servertype">ServerType</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#startservers">StartServers</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#threadsperchild">ThreadsPerChild</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#timeout">TimeOut</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#usecanonicalname">UseCanonicalName</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#user">User</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><A HREF="#virtualhost">&lt;VirtualHost&gt;</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="accessconfig">AccessConfig directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt AccessConfig} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Syntax"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah><STRONG>Syntax:</STRONG></A> AccessConfig <EM>filename</EM><BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah><STRONG>Default:</STRONG></A> <CODE>AccessConfig conf/access.conf</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe server will read this file for more directives after reading the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#resourceconfig">ResourceConfig</A> file. <EM>Filename</EM> is
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahrelative to the <A HREF="#serverroot">ServerRoot</A>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis feature can be disabled using:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>AccessConfig /dev/null</CODE></BLOCKQUOTE>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahHistorically, this file only contained
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="#directory">&lt;Directory&gt;</A> sections; in fact it can now
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahcontain any server directive allowed in the <EM>server config</EM> context.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<H2><A NAME="accessfilename">AccessFileName directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt AccessFileName} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand><STRONG>Syntax:</STRONG></A> AccessFileName <EM>filename filename ...</EM><BR>
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<A
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand HREF="directive-dict.html#Default"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah><STRONG>Default:</STRONG></A> <CODE>AccessFileName .htaccess</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> AccessFileName can accept more than
25cf1a301a396c38e8adf52c15f537b80d2483f7jlone filename only in Apache 1.3 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlWhen returning a document to the client the server looks for the first existing
25cf1a301a396c38e8adf52c15f537b80d2483f7jlaccess control file from this list of names in every directory of the path to
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe document, if access control files are enabled for that directory.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlFor example:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>AccessFileName .acl</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbefore returning the document /usr/local/web/index.html, the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver will read /.acl, /usr/.acl, /usr/local/.acl and /usr/local/web/.acl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfor directives, unless they have been disabled with
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory /&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllowOverride None<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/Directory&gt;</CODE></BLOCKQUOTE><P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="addmodule">AddModule directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt AddModule} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> AddModule <EM>module module ...</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config <BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> AddModule is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.2 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe server can have modules compiled in which are not actively in use.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive can be used to enable the use of those modules. The
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver comes with a pre-loaded list of active modules; this list can
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbe cleared with the <A HREF="#clearmodulelist">ClearModuleList</A>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahdirective.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="allowoverride">AllowOverride directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt AllowOverride} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Syntax"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah><STRONG>Syntax:</STRONG></A> AllowOverride <EM>override override ...</EM><BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Default"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>AllowOverride All</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> directory<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahWhen the server finds an .htaccess file (as specified by
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="#accessfilename">AccessFileName</A>) it needs to know which
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahdirectives declared in that file can override earlier access information.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<EM>Override</EM> can be set to <CODE>None</CODE>, in which case the server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwill not read the file, <CODE>All</CODE> in which case the server will
25cf1a301a396c38e8adf52c15f537b80d2483f7jlallow all the directives, or one or more of the following:
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<DL>
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<DT>AuthConfig
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<DD>
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<!--%plaintext &lt;?INDEX {\tt AuthConfig} override&gt; -->
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimandAllow use of the authorization directives
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(<A HREF="mod_auth_dbm.html#authdbmgroupfile">AuthDBMGroupFile</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_auth_dbm.html#authdbmuserfile">AuthDBMUserFile</A>,
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#authname">AuthName</A>, <A HREF="#authtype">AuthType</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_auth.html#authuserfile">AuthUserFile</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#require">require</A>, <EM>etc.</EM>).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT>FileInfo
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DD>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<!--%plaintext &lt;?INDEX {\tt FileInfo} override&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllow use of the directives controlling document types
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(<A HREF="mod_mime.html#addencoding">AddEncoding</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_mime.html#addlanguage">AddLanguage</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_mime.html#addtype">AddType</A>,
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="#defaulttype">DefaultType</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#errordocument">ErrorDocument</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_negotiation.html#languagepriority">LanguagePriority</A>, <EM>etc.</EM>).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT>Indexes
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DD>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt Indexes} override&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllow use of the directives controlling directory indexing
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(<A HREF="mod_autoindex.html#adddescription">AddDescription</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#addicon">AddIcon</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#addiconbyencoding">AddIconByEncoding</A>,
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="mod_autoindex.html#addiconbytype">AddIconByType</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#defaulticon">DefaultIcon</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_dir.html#directoryindex">DirectoryIndex</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#fancyindexing">FancyIndexing</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#headername">HeaderName</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#indexignore">IndexIgnore</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#indexoptions">IndexOptions</A>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_autoindex.html#readmename">ReadmeName</A>, <EM>etc.</EM>).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT>Limit
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DD>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<!--%plaintext &lt;?INDEX {\tt Limit} override&gt; -->
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahAllow use of the directives controlling host access (allow, deny and order).
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<DT>Options
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<DD>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<!--%plaintext &lt;?INDEX {\tt Options} override&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllow use of the directives controlling specific directory features
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah(<A HREF="#options">Options</A> and
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="mod_include.html#xbithack">XBitHack</A>).
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah</DL><P><HR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<H2><A NAME="authname">AuthName directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt AuthName} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> AuthName <EM>auth-domain</EM><BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> AuthConfig<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah><STRONG>Status:</STRONG></A> core<P>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahThis directive sets the name of the authorization realm for a directory.
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahThis realm is given to the client so that the user knows which username and
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahpassword to send. <SAMP>AuthName</SAMP> takes a single argument;
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahif the realm name contains spaces, it must be enclosed in quotation marks.
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuahIt must be accompanied by <A HREF="#authtype">AuthType</A> and
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="#require">require</A> directives, and directives such as
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="authtype">AuthType directive</A></H2>
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<!--%plaintext &lt;?INDEX {\tt AuthType} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand><STRONG>Syntax:</STRONG></A> AuthType <EM>type</EM><BR>
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand<A
febcc4a52c3ed7fe3a106da2c2ba52c56afd5111jimand HREF="directive-dict.html#Context"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> AuthConfig<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah HREF="directive-dict.html#Status"
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive selects the type of user authentication for a directory.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlOnly <CODE>Basic</CODE> and <CODE>Digest</CODE> are currently implemented.
1e2e7a75ddb1eedcefa449ce98fd5862749b72eehuah<!--%plaintext &lt;?INDEX {\tt Basic} authentication scheme&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIt must be accompanied by <A HREF="#authname">AuthName</A> and
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#require">require</A> directives, and directives such as
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="bindaddress">BindAddress directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt BindAddress} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> BindAddress <EM>saddr</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>BindAddress *</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlA Unix&#174; http server can either listen for connections to every
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIP address of the server machine, or just one IP address of the server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmachine. <EM>Saddr</EM> can be
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<MENU>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>*
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>An IP address
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>A fully-qualified Internet domain name
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</MENU>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIf the value is *, then the server will listen for connections on
25cf1a301a396c38e8adf52c15f537b80d2483f7jlevery IP address, otherwise it will only listen on the IP address
25cf1a301a396c38e8adf52c15f537b80d2483f7jlspecified. <P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlOnly one <CODE>BindAddress</CODE> directive can be used. For more
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcontrol over which address and ports Apache listens to, use the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE><A HREF="#listen">Listen</A></CODE> directive instead of
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>BindAddress</CODE>.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>BindAddress</CODE> can be used as an alternative method for
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsupporting <A HREF="/vhosts/index.html">virtual hosts</A> using
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmultiple independent servers, instead of using <CODE><A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#virtualhost">&lt;VirtualHost&gt;</A></CODE> sections.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>See Also:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/dns-caveats.html">DNS Issues</A><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See Also:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/bind.html">Setting which addresses and ports Apache uses</A></P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="bs2000account">BS2000Account directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt BS2000Account} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> BS2000Account <EM>account</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <EM>none</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> BS2000Account is only available for
25cf1a301a396c38e8adf52c15f537b80d2483f7jlBS2000 machines, as of Apache 1.3 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe <CODE>BS2000Account</CODE> directive is available for BS2000 hosts
25cf1a301a396c38e8adf52c15f537b80d2483f7jlonly. It must be used to define the account number for the non-privileged
25cf1a301a396c38e8adf52c15f537b80d2483f7jlapache server user (which was configured using the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#user">User</A> directive).
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis is required by the BS2000 POSIX subsystem (to change the underlying
25cf1a301a396c38e8adf52c15f537b80d2483f7jlBS2000 task environment by performing a sub-LOGON) to prevent CGI scripts
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrom accessing resources of the privileged account which started the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver, usually <SAMP>SYSROOT</SAMP>.<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlOnly one <CODE>BS2000Account</CODE> directive can be used. <P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>See Also:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/ebcdic.html">Apache EBCDIC port</A></P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="clearmodulelist">ClearModuleList directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt ClearModuleList} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> ClearModuleList<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> ClearModuleList is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.2 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe server comes with a built-in list of active modules. This
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirective clears the list. It is assumed that the list will then be
25cf1a301a396c38e8adf52c15f537b80d2483f7jlre-populated using the <A HREF="#addmodule">AddModule</A> directive.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="contentdigest">ContentDigest directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt ContentDigest} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> ContentDigest <EM>on|off</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>ContentDigest off</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl.htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> Options<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> experimental<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> ContentDigest is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.1 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive enables the generation of <CODE>Content-MD5</CODE> headers
25cf1a301a396c38e8adf52c15f537b80d2483f7jlas defined in RFC1864 respectively RFC2068.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlMD5 is an algorithm for computing a "message digest" (sometimes called
25cf1a301a396c38e8adf52c15f537b80d2483f7jl"fingerprint") of arbitrary-length data, with a high degree of confidence
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthat any alterations in the data will be reflected in alterations in the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmessage digest.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe <CODE>Content-MD5</CODE> header provides an end-to-end message
25cf1a301a396c38e8adf52c15f537b80d2483f7jlintegrity check (MIC) of the entity-body. A proxy or client may check this
25cf1a301a396c38e8adf52c15f537b80d2483f7jlheader for detecting accidental modification of the entity-body
25cf1a301a396c38e8adf52c15f537b80d2483f7jlin transit.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlExample header:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE> Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==</PRE><P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote that this can cause performance problems on your server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsince the message digest is computed on every request
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(the values are not cached).<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>Content-MD5</CODE> is only sent for documents served by the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcore, and not by any module. For example, SSI documents, output from
25cf1a301a396c38e8adf52c15f537b80d2483f7jlCGI scripts, and byte range responses do not have this header.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="coredumpdirectory">CoreDumpDirectory directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt CoreDumpDirectory} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> CoreDumpDirectory <EM>directory</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> the same location as ServerRoot<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis controls the directory to which Apache attempts to switch before
25cf1a301a396c38e8adf52c15f537b80d2483f7jldumping core. The default is in the <A HREF="#serverroot">ServerRoot</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectory, however since this should not be writable by the user
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe server runs as, core dumps won't normally get written. If you
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwant a core dump for debugging, you can use this directive to place
25cf1a301a396c38e8adf52c15f537b80d2483f7jlit in a different location.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="defaulttype">DefaultType directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt DefaultType} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> DefaultType <EM>MIME-type</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>DefaultType text/html</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl.htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> FileInfo<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThere will be times when the server is asked to provide a document
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwhose type cannot be determined by its MIME types mappings.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe server must inform the client of the content-type of the document, so in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe event of an unknown type it uses the <CODE>DefaultType</CODE>. For
25cf1a301a396c38e8adf52c15f537b80d2483f7jlexample:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>DefaultType image/gif</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwould be appropriate for a directory which contained many gif images
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwith filenames missing the .gif extension.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="directory">&lt;Directory&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt Directory} section directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;Directory <EM>directory</EM>&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl ... &lt;/Directory&gt; <BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core. <P>
63360950109af2ce85a962ca61f40b8782f11100mp
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory&gt; and &lt;/Directory&gt; are used to enclose a group of
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectives which will apply only to the named directory and sub-directories
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof that directory. Any directive which is allowed in a directory
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcontext may be used. <EM>Directory</EM> is either the full path to a directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlor a wild-card string. In a wild-card string, `?' matches any single character,
25cf1a301a396c38e8adf52c15f537b80d2483f7jland `*' matches any sequences of characters. As of Apache 1.3, you
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmay also use `[]' character ranges like in the shell. Also as of Apache 1.3
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnone of the wildcards match a `/' character, which more closely mimics the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbehaviour of Unix shells.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlExample:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Directory /usr/local/httpd/htdocs&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Options Indexes FollowSymLinks
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;/Directory&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>Apache 1.2 and above:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlExtended regular expressions can also be used, with the addition of the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>~</CODE> character. For example:</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Directory ~ &quot;^/www/.*/[0-9]{3}&quot;&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwould match directories in /www/ that consisted of three numbers.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>If multiple (non-regular expression) directory sections match the
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectory (or its parents) containing
25cf1a301a396c38e8adf52c15f537b80d2483f7jla document, then the directives are applied in the order of shortest match
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfirst, interspersed with the directives from the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#accessfilename">.htaccess</A> files. For example, with
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory /&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllowOverride None<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/Directory&gt;<BR><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory /home/*&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAllowOverride FileInfo<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/Directory&gt;</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfor access to the document <CODE>/home/web/dir/doc.html</CODE> the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsteps are:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<MENU>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>Apply directive <CODE>AllowOverride None</CODE> (disabling
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>.htaccess</CODE> files).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>Apply directive <CODE>AllowOverride FileInfo</CODE> (for directory
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>/home/web</CODE>).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>Apply any FileInfo directives in <CODE>/home/web/.htaccess</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</MENU>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlRegular expression directory sections are handled slightly differently
25cf1a301a396c38e8adf52c15f537b80d2483f7jlby Apache 1.2 and 1.3. In Apache 1.2 they are interspersed with the normal
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectory sections and applied in the order they appear in the configuration
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfile. They are applied only once, and apply when the shortest match
25cf1a301a396c38e8adf52c15f537b80d2483f7jlpossible occurs. In Apache 1.3 regular expressions are not considered
25cf1a301a396c38e8adf52c15f537b80d2483f7jluntil after all of the normal sections have been applied. Then all of
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe regular expressions are tested in the order they appeared in the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlconfiguration file. For example, with
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory ~ abc$&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl... directives here ...<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/Directory&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSuppose that the filename being accessed is
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>/home/abc/public_html/abc/index.html</CODE>. The server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlconsiders each of <CODE>/</CODE>, <CODE>/home</CODE>, <CODE>/home/abc</CODE>,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>/home/abc/public_html</CODE>, and <CODE>/home/abc/public_html/abc</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlin that order. In Apache 1.2, when
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>/home/abc</CODE> is considered, the regular expression will match
25cf1a301a396c38e8adf52c15f537b80d2483f7jland be applied. In Apache 1.3 the regular expression isn't considered
25cf1a301a396c38e8adf52c15f537b80d2483f7jlat all at that point in the tree. It won't be considered until after
25cf1a301a396c38e8adf52c15f537b80d2483f7jlall normal &lt;Directory&gt;s and <CODE>.htaccess</CODE> files have
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbeen applied. Then the regular expression will
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmatch on <CODE>/home/abc/public_html/abc</CODE> and be applied.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote that the default Apache access for &lt;Directory /&gt; is
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<SAMP>Allow from All</SAMP>. This means that Apache will serve any file
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmapped from an URL. It is recommended that you change this with a block
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsuch as
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Directory /&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Order Deny,Allow
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Deny from All
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;/Directory&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jland then override this for directories you <EM>want</EM> accessible.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSee the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="/misc/security_tips.html"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl>Security Tips</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlpage for more details.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe directory sections typically occur in the access.conf file, but they
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmay appear in any configuration file. &lt;Directory&gt; directives cannot
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnest, and cannot appear in a <A HREF="#limit">&lt;Limit&gt;</A> or
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#limitexcept">&lt;LimitExcept&gt;</A> section.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlLocation and Files sections work</A> for an explanation of how these
25cf1a301a396c38e8adf52c15f537b80d2483f7jldifferent sections are combined when a request is received
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="directorymatch">&lt;DirectoryMatch&gt;</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;DirectoryMatch <EM>regex</EM>&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl ... &lt;/DirectoryMatch&gt; <BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core.<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> Available in Apache 1.3 and later
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>&lt;DirectoryMatch&gt; and &lt;/DirectoryMatch&gt; are used to enclose a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlgroup of
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectives which will apply only to the named directory and sub-directories
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof that directory, the same as <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#directory">&lt;Directory&gt;</A>. However, it takes as an
25cf1a301a396c38e8adf52c15f537b80d2483f7jlargument a regular expression. For example:</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;DirectoryMatch &quot;^/www/.*/[0-9]{3}&quot;&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>would match directories in /www/ that consisted of three numbers.</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>See Also:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#directory">&lt;Directory&gt;</A> for a description of how
25cf1a301a396c38e8adf52c15f537b80d2483f7jlregular expressions are mixed in with normal &lt;Directory&gt;s.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlLocation and Files sections work</A> for an explanation of how these
25cf1a301a396c38e8adf52c15f537b80d2483f7jldifferent sections are combined when a request is received
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="documentroot">DocumentRoot directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt DocumentRoot} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> DocumentRoot <EM>directory-filename</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>DocumentRoot
25cf1a301a396c38e8adf52c15f537b80d2483f7jl/usr/local/apache/htdocs</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive sets the directory from which httpd will serve files.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlUnless matched by a directive like Alias, the server appends the path
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrom the requested URL to the document root to make the path to the
25cf1a301a396c38e8adf52c15f537b80d2483f7jldocument. Example:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>DocumentRoot /usr/web</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthen an access to <CODE>http://www.my.host.com/index.html</CODE> refers
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto <CODE>/usr/web/index.html</CODE>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>There appears to be a bug in mod_dir which causes problems when the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlDocumentRoot has a trailing slash (<EM>i.e.</EM>, "DocumentRoot /usr/web/") so
25cf1a301a396c38e8adf52c15f537b80d2483f7jlplease avoid that.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="errordocument">ErrorDocument directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt ErrorDocument} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> ErrorDocument <EM>error-code document</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl.htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> FileInfo<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> The directory and .htaccess contexts
25cf1a301a396c38e8adf52c15f537b80d2483f7jlare only available in Apache 1.1 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIn the event of a problem or error, Apache can be configured to do
25cf1a301a396c38e8adf52c15f537b80d2483f7jlone of four things,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<OL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>output a simple hardcoded error message
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>output a customized message
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>redirect to a local URL to handle the problem/error
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>redirect to an external URL to handle the problem/error
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</OL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The first option is the default, while options 2-4 are configured
25cf1a301a396c38e8adf52c15f537b80d2483f7jlusing the <CODE>ErrorDocument</CODE> directive, which is followed by
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe HTTP response code and a message or URL.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><EM>Messages</EM> in this context begin with a single quote
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(<CODE>"</CODE>), which does not form part of the message itself.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache will sometimes offer additional information regarding the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlproblem/error.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>URLs can begin with a slash (/) for local URLs, or be a full
25cf1a301a396c38e8adf52c15f537b80d2483f7jlURL which the client can resolve. Examples:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlErrorDocument 500 http://foo.example.com/cgi-bin/tester<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlErrorDocument 404 /cgi-bin/bad_urls.pl<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlErrorDocument 401 /subscription_info.html<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlErrorDocument 403 "Sorry can't allow you access today
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>Note that when you specify an <CODE>ErrorDocument</CODE> that
25cf1a301a396c38e8adf52c15f537b80d2483f7jlpoints to a remote URL (ie. anything with a method such as "http" in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfront of it) Apache will send a redirect to the client to tell it
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwhere to find the document, even if the document ends up being
25cf1a301a396c38e8adf52c15f537b80d2483f7jlon the same server.. This has several implications, the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmost important being that <STRONG>if you use an "ErrorDocument 401"
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirective then it must refer to a local document.</STRONG> This results
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrom the nature of the HTTP basic authentication scheme.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>See Also: <A HREF="/custom-error.html">documentation of customizable
25cf1a301a396c38e8adf52c15f537b80d2483f7jlresponses.</A><P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="errorlog">ErrorLog directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt ErrorLog} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> ErrorLog <EM>filename</EM>|<CODE>syslog[:facility]</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>ErrorLog logs/error_log</CODE> (Unix)<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>ErrorLog logs/error.log</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl (Windows and OS/2)<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe error log directive sets the name of the file to which the server will log
25cf1a301a396c38e8adf52c15f537b80d2483f7jlany errors it encounters. If the filename does not begin with a slash (/)
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthen it is assumed to be relative to the <A HREF="#serverroot">ServerRoot</A>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIf the filename begins with a pipe (|) then it is assumed to be a command to
25cf1a301a396c38e8adf52c15f537b80d2483f7jlspawn to handle the error log.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>Apache 1.3 and above:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlUsing <CODE>syslog</CODE> instead of a filename enables logging via syslogd(8)
25cf1a301a396c38e8adf52c15f537b80d2483f7jlif the system supports it. The default is to use syslog facility
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>local7</CODE>, but you can override this by using the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>syslog:</CODE><EM>facility</EM> syntax where <EM>facility</EM> can be
25cf1a301a396c38e8adf52c15f537b80d2483f7jlone of the names usually documented in syslog(1).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSECURITY: See the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/misc/security_tips.html#serverroot">security tips</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jldocument for details on why your security could be compromised if
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe directory where logfiles are stored is writable by anyone other
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthan the user that starts the server.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>See also:</STRONG> <A HREF="#loglevel">LogLevel</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="files">&lt;Files&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;Files <EM>filename</EM>&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl... &lt;/Files&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, .htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> only available in Apache
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.2 and above.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The &lt;Files&gt; directive provides for access control by
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfilename. It is comparable to the <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#directory">&lt;Directory&gt;</A> directive and
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#location">&lt;Location&gt;</A> directives. It
25cf1a301a396c38e8adf52c15f537b80d2483f7jlshould be matched with a &lt;/Files&gt; directive. The
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectives given within this section will be applied to any
25cf1a301a396c38e8adf52c15f537b80d2483f7jlobject with a basename (last component of filename) matching
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe specified filename.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>&lt;Files&gt;</CODE> sections are processed in the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlorder they appear in the configuration file, after the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Directory&gt; sections and <CODE>.htaccess</CODE> files are
25cf1a301a396c38e8adf52c15f537b80d2483f7jlread, but before &lt;Location&gt; sections. Note that
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Files&gt; can be nested inside &lt;Directory&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsections to restrict the portion of the filesystem they
25cf1a301a396c38e8adf52c15f537b80d2483f7jlapply to.</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The <EM>filename</EM> argument should include a filename, or a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwild-card string, where `?' matches any single character, and `*' matches any
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsequences of characters. Extended regular expressions can also be used,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwith the addition of
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe <CODE>~</CODE> character. For example:</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Files ~ &quot;\.(gif|jpe?g|png)$&quot;&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwould match most common Internet graphics formats. In Apache 1.3 and
25cf1a301a396c38e8adf52c15f537b80d2483f7jllater, <A HREF="#filesmatch">&lt;FilesMatch&gt;</A> is preferred,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlhowever.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>Note that unlike <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#directory"><CODE>&lt;Directory&gt;</CODE></A> and <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#location"><CODE>&lt;Location&gt;</CODE></A> sections,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>&lt;Files&gt;</CODE> sections can be used inside .htaccess
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfiles. This allows users to control access to their own files, at a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfile-by-file level.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlLocation and Files sections work</A> for an explanation of how these
25cf1a301a396c38e8adf52c15f537b80d2483f7jldifferent sections are combined when a request is received
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="filesmatch">&lt;FilesMatch&gt;</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;FilesMatch <EM>regex</EM>&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl... &lt;/FilesMatch&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, .htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> only available in Apache
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.3 and above.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The &lt;FilesMatch&gt; directive provides for access control by
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfilename, just as the <A HREF="#files">&lt;Files&gt;</A> directive
25cf1a301a396c38e8adf52c15f537b80d2483f7jldoes. However, it accepts a regular expression. For example:</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;FilesMatch &quot;\.(gif|jpe?g|png)$&quot;&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>would match most common Internet graphics formats.</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlLocation and Files sections work</A> for an explanation of how these
25cf1a301a396c38e8adf52c15f537b80d2483f7jldifferent sections are combined when a request is received
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="group">Group directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt Group} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> Group <EM>unix-group</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>Group #-1</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe Group directive sets the group under which the server will answer requests.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIn order to use this directive, the stand-alone server must be run initially
25cf1a301a396c38e8adf52c15f537b80d2483f7jlas root. <EM>Unix-group</EM> is one of:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT>A group name
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DD>Refers to the given group by name.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT># followed by a group number.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DD>Refers to a group by its number.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</DL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlIt is recommended that you set up a new group specifically for running the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver. Some admins use user <CODE>nobody</CODE>, but this is not always
25cf1a301a396c38e8adf52c15f537b80d2483f7jlpossible or desirable.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote: if you start the server as a non-root user, it will fail to change
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywto the specified group, and will instead continue to run as the group of the
f7832c8d6c8b1d0020951f2b254dca0a6a741824hyworiginal user. <P>
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimand
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimandSpecial note: Use of this directive in &lt;VirtualHost&gt; requires a
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimandproperly configured <A HREF="/suexec.html">suEXEC wrapper</A>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlWhen used inside a &lt;VirtualHost&gt; in this manner, only the group
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthat CGIs are run as is affected. Non-CGI requests are still processed
25cf1a301a396c38e8adf52c15f537b80d2483f7jlas the group specified in the main Group directive.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimandSECURITY: See <A HREF="#user">User</A> for a discussion of the security
25cf1a301a396c38e8adf52c15f537b80d2483f7jlconsiderations.<P><HR>
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimand
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimand<H2><A NAME="hostnamelookups">HostNameLookups directive</A></H2>
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimand<!--%plaintext &lt;?INDEX {\tt HostNameLookups} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
3cbfd4cf9e3b91b2efed73184d8c6dc586fc1935jimand HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> HostNameLookups <EM>on | off | double</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
f7832c8d6c8b1d0020951f2b254dca0a6a741824hyw><STRONG>Default:</STRONG></A> <CODE>HostNameLookups off</CODE><BR>
f7832c8d6c8b1d0020951f2b254dca0a6a741824hyw<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
e98fafb9956429b59c817d4fbd27720c73879203jl HREF="directive-dict.html#Compatibility"
e98fafb9956429b59c817d4fbd27720c73879203jl REL="Help"
e98fafb9956429b59c817d4fbd27720c73879203jl><STRONG>Compatibility:</STRONG></A> <CODE>double</CODE> available only in
e98fafb9956429b59c817d4fbd27720c73879203jlApache
e98fafb9956429b59c817d4fbd27720c73879203jl1.3 and above.<BR>
e98fafb9956429b59c817d4fbd27720c73879203jl<A
e98fafb9956429b59c817d4fbd27720c73879203jl HREF="directive-dict.html#Compatibility"
e98fafb9956429b59c817d4fbd27720c73879203jl REL="Help"
e98fafb9956429b59c817d4fbd27720c73879203jl><STRONG>Compatibility:</STRONG></A> Default was <CODE>on</CODE> prior to
e98fafb9956429b59c817d4fbd27720c73879203jlApache 1.3.<P>
e98fafb9956429b59c817d4fbd27720c73879203jl
e98fafb9956429b59c817d4fbd27720c73879203jlThis directive enables DNS lookups so that host names can be logged (and
e98fafb9956429b59c817d4fbd27720c73879203jlpassed to CGIs/SSIs in <CODE>REMOTE_HOST</CODE>).
e98fafb9956429b59c817d4fbd27720c73879203jlThe value <CODE>double</CODE> refers to doing double-reverse DNS.
e98fafb9956429b59c817d4fbd27720c73879203jlThat is, after a reverse lookup is performed, a forward lookup is then
e98fafb9956429b59c817d4fbd27720c73879203jlperformed on that result. At least one of the ip addresses in the forward
e98fafb9956429b59c817d4fbd27720c73879203jllookup must match the original address. (In "tcpwrappers" terminology
e98fafb9956429b59c817d4fbd27720c73879203jlthis is called <CODE>PARANOID</CODE>.)<P>
e98fafb9956429b59c817d4fbd27720c73879203jl
e98fafb9956429b59c817d4fbd27720c73879203jlRegardless of the setting, when <A HREF="mod_access.html">mod_access</A>
e98fafb9956429b59c817d4fbd27720c73879203jlis used for controlling access by hostname, a double reverse lookup
e98fafb9956429b59c817d4fbd27720c73879203jlwill be performed. This is necessary for security. Note that the
e98fafb9956429b59c817d4fbd27720c73879203jlresult of this double-reverse isn't generally available unless
e98fafb9956429b59c817d4fbd27720c73879203jlyou set <CODE>HostnameLookups double</CODE>. For example, if only
e98fafb9956429b59c817d4fbd27720c73879203jl<CODE>HostnameLookups on</CODE> and a request is made to an object that
e98fafb9956429b59c817d4fbd27720c73879203jlis protected by hostname restrictions, regardless of whether the
e98fafb9956429b59c817d4fbd27720c73879203jldouble-reverse fails or not, CGIs will still be passed the single-reverse
e98fafb9956429b59c817d4fbd27720c73879203jlresult in <CODE>REMOTE_HOST</CODE>.<P>
e98fafb9956429b59c817d4fbd27720c73879203jl
e98fafb9956429b59c817d4fbd27720c73879203jlThe default for this directive was previously <CODE>on</CODE> in
e98fafb9956429b59c817d4fbd27720c73879203jlversions of Apache prior to 1.3. It was changed to <CODE>off</CODE>
e98fafb9956429b59c817d4fbd27720c73879203jlin order to save the network traffic for those sites that don't truly
e98fafb9956429b59c817d4fbd27720c73879203jlneed the reverse lookups done. It is also better for the end users
e98fafb9956429b59c817d4fbd27720c73879203jlbecause they don't have to suffer the extra latency that a lookup
e98fafb9956429b59c817d4fbd27720c73879203jlentails.
e98fafb9956429b59c817d4fbd27720c73879203jlHeavily loaded sites should leave this directive <CODE>off</CODE>, since DNS
e98fafb9956429b59c817d4fbd27720c73879203jllookups can take considerable amounts of time. The utility <EM>logresolve</EM>,
e98fafb9956429b59c817d4fbd27720c73879203jlprovided in the <EM>/support</EM> directory, can be used to look up host names
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrom logged IP addresses offline.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="identitycheck">IdentityCheck directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt IdentityCheck} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> IdentityCheck <EM>boolean</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>IdentityCheck off</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive enables RFC1413-compliant logging of the remote user name
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfor each connection, where the client machine runs identd or something similar.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis information is logged in the access log. <EM>Boolean</EM> is either
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>on</CODE> or <CODE>off</CODE>.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe information should not be trusted in any way except for rudimentary usage
25cf1a301a396c38e8adf52c15f537b80d2483f7jltracking.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote that this can cause serious latency problems accessing your server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsince every request requires one of these lookups to be performed. When
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfirewalls are involved each lookup might possibly fail and add 30 seconds
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof latency to each hit. So in general this is not very useful on public
25cf1a301a396c38e8adf52c15f537b80d2483f7jlservers accessible from the Internet.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="ifdefine">&lt;IfDefine&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;IfDefine [!]<EM>parameter-name</EM>&gt; <EM>...</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/IfDefine&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> None<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> all<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> &lt;IfDefine&gt; is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.3.1 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe &lt;IfDefine <EM>test</EM>&gt;...&lt;/IfDefine&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsection is used to mark directives that are conditional. The
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectives within an IfDefine section are only
25cf1a301a396c38e8adf52c15f537b80d2483f7jlprocessed if the <EM>test</EM> is true. If <EM>test</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis false, everything between the start and end markers
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis ignored.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe <EM>test</EM> in the &lt;IfDefine&gt; section directive
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcan be one of two forms:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><EM>parameter-name</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><CODE>!</CODE><EM>parameter-name</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>In the former case, the directives between the start and end markers are
25cf1a301a396c38e8adf52c15f537b80d2483f7jlonly processed if the parameter named <EM>parameter-name</EM> is defined.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe second format reverses the test, and only processes the directives if
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<EM>parameter-name</EM> is <STRONG>not</STRONG> defined.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The <EM>parameter-name</EM> argument is a define as given on the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>httpd</CODE> command line via <CODE>-D</CODE><EM>parameter-</EM>, at the
25cf1a301a396c38e8adf52c15f537b80d2483f7jltime the server was started.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>&lt;IfDefine&gt; sections are nest-able, which can be used to implement
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsimple multiple-parameter tests.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlExample:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl $ httpd -DReverseProxy ...
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl # httpd.conf
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;IfDefine ReverseProxy&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl LoadModule rewrite_module libexec/mod_rewrite.so
25cf1a301a396c38e8adf52c15f537b80d2483f7jl LoadModule proxy_module libexec/libproxy.so
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;/IfDefine&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P> <HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="ifmodule">&lt;IfModule&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> &lt;IfModule [!]<EM>module-name</EM>&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <EM>...</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/IfModule&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> None<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> all<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> IfModule is only available in 1.2 and
25cf1a301a396c38e8adf52c15f537b80d2483f7jllater.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe &lt;IfModule <EM>test</EM>&gt;...&lt;/IfModule&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsection is used to mark directives that are conditional. The
25cf1a301a396c38e8adf52c15f537b80d2483f7jldirectives within an IfModule section are only
25cf1a301a396c38e8adf52c15f537b80d2483f7jlprocessed if the <EM>test</EM> is true. If <EM>test</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis false, everything between the start and end markers
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis ignored.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe <EM>test</EM> in the &lt;IfModule&gt; section directive
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcan be one of two forms:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI><EM>module name</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>!<EM>module name</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>In the former case, the directives between the start and end markers
25cf1a301a396c38e8adf52c15f537b80d2483f7jlare only processed if the module named <EM>module name</EM> is compiled
25cf1a301a396c38e8adf52c15f537b80d2483f7jlin to Apache. The second format reverses the test, and only processes
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe directives if <EM>module name</EM> is <STRONG>not</STRONG> compiled in.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The <EM>module name</EM> argument is a module name as given as the file
25cf1a301a396c38e8adf52c15f537b80d2483f7jlname of the module, at the time it was compiled. For example,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>mod_rewrite.c</CODE>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>&lt;IfModule&gt; sections are nest-able, which can be used to implement
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsimple multiple-module tests.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P> <HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="include">Include directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>Syntax:</STRONG> Include <EM>filename</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> Include is only available in Apache 1.3
25cf1a301a396c38e8adf52c15f537b80d2483f7jland later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive allows inclusion of other configuration files from within the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver configuration files.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P> <HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="keepalive">KeepAlive directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>Syntax: (Apache 1.1)</STRONG> KeepAlive <EM>max-requests</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>Default: (Apache 1.1)</STRONG> <CODE>KeepAlive 5</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>Syntax: (Apache 1.2)</STRONG> KeepAlive <EM>on/off</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>Default: (Apache 1.2)</STRONG> <CODE>KeepAlive On</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> KeepAlive is only available in Apache
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.1 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive enables
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/keepalive.html">Keep-Alive</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsupport.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>Apache 1.1</STRONG>: Set <EM>max-requests</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto the maximum number of requests you want Apache to entertain per
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequest. A limit is imposed to prevent a client from hogging your
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver resources. Set this to <CODE>0</CODE> to disable support.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>Apache 1.2 and later</STRONG>: Set to "On" to enable
25cf1a301a396c38e8adf52c15f537b80d2483f7jlpersistent connections, "Off" to disable. See also the <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#maxkeepaliverequests">MaxKeepAliveRequests</A> directive.</P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="keepalivetimeout">KeepAliveTimeout directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> KeepAliveTimeout <EM>seconds</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>KeepAliveTimeout 15</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> Core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> KeepAliveTimeout is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.1 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe number of seconds Apache will wait for a subsequent request before
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclosing the connection. Once a request has been received, the timeout
25cf1a301a396c38e8adf52c15f537b80d2483f7jlvalue specified by the <A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#timeout"><CODE>Timeout</CODE></A> directive
25cf1a301a396c38e8adf52c15f537b80d2483f7jlapplies.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limit">&lt;Limit&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt Limit} section directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Limit <EM>method method</EM> ... &gt; ... &lt;/Limit&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> any<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAccess controls are normally effective for <STRONG>all</STRONG> access
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmethods, and this is the usual desired behaviour. <STRONG>In the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlgeneral case, access control directives should not be placed within a
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>&lt;limit&gt;</CODE> section.</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The purpose of the &lt;Limit&gt; directive is to restrict the effect
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof the access controls to the nominated HTTP methods. For all other
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmethods, the access restrictions that are enclosed in the
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Limit&gt; bracket <STRONG>will have no effect</STRONG>. The
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfollowing example applies the access control only to the methods POST,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlPUT, and DELETE, leaving all other methods unprotected:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;Limit POST PUT DELETE&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequire valid-user<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;/Limit&gt;</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe method names listed can be one or more of: GET, POST, PUT, DELETE,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlCONNECT, OPTIONS, TRACE, PATCH, PROPFIND, PROPPATCH, MKCOL, COPY,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlMOVE, LOCK, and UNLOCK. <STRONG>The method name is
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcase-sensitive.</STRONG> If GET is used it will also restrict HEAD
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequests.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limitexcept">&lt;LimitExcept&gt; directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt LimitExcept} section directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;LimitExcept <EM>method method</EM> ... &gt; ... &lt;/LimitExcept&gt;<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> any<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> Available in Apache 1.3.5 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl&lt;LimitExcept&gt; and &lt;/LimitExcept&gt; are used to enclose a group of
25cf1a301a396c38e8adf52c15f537b80d2483f7jlaccess control directives which will then apply to any HTTP access method
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>not</STRONG> listed in the arguments; i.e., it is the opposite of a
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#limit">&lt;Limit&gt;</A> section and can be used to control both
25cf1a301a396c38e8adf52c15f537b80d2483f7jlstandard and nonstandard/unrecognized methods. See the documentation for
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#limit">&lt;Limit&gt;</A> for more details.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limitrequestbody">LimitRequestBody directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt LimitRequestBody} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
2dd3029adb4864ebca3dd9cd6dad5fc4d38abff6jimand REL="Help"
2dd3029adb4864ebca3dd9cd6dad5fc4d38abff6jimand><STRONG>Syntax:</STRONG></A> LimitRequestBody <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LimitRequestBody 0</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl.htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> LimitRequestBody is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.3.2 and later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<EM>Number</EM> is a long integer from 0 (meaning unlimited) to 2147483647
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(2GB). The default value is defined by the compile-time constant
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>DEFAULT_LIMIT_REQUEST_BODY</CODE> (0 as distributed).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe LimitRequestBody directive allows the user to set a
25cf1a301a396c38e8adf52c15f537b80d2483f7jllimit on the allowed size of an HTTP request message body within
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe context in which the directive is given (server, per-directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlper-file or per-location). If the client request exceeds that limit,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe server will return an error response instead of servicing the request.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe size of a normal request message body will vary greatly depending
25cf1a301a396c38e8adf52c15f537b80d2483f7jlon the nature of the resource and the methods allowed on that resource.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlCGI scripts typically use the message body for passing form information
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto the server. Implementations of the PUT method will require a value
25cf1a301a396c38e8adf52c15f537b80d2483f7jlat least as large as any representation that the server wishes
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto accept for that resource.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive gives the server administrator greater control over abnormal
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclient request behavior, which may be useful for avoiding some forms
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof denial-of-service attacks.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limitrequestfields">LimitRequestFields directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt LimitRequestFields} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> LimitRequestFields <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LimitRequestFields 100</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> LimitRequestFields is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.3.2 and later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<EM>Number</EM> is an integer from 0 (meaning unlimited) to 32767.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe default value is defined by the compile-time constant
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>DEFAULT_LIMIT_REQUEST_FIELDS</CODE> (100 as distributed).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe LimitRequestFields directive allows the server administrator to modify
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe limit on the number of request header fields allowed in an HTTP request.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlA server needs this value to be larger than the number of fields that a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnormal client request might include. The number of request header fields
25cf1a301a396c38e8adf52c15f537b80d2483f7jlused by a client rarely exceeds 20, but this may vary among different
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclient implementations, often depending upon the extent to which a user
25cf1a301a396c38e8adf52c15f537b80d2483f7jlhas configured their browser to support detailed content negotiation.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlOptional HTTP extensions are often expressed using request header fields.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive gives the server administrator greater control over abnormal
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclient request behavior, which may be useful for avoiding some forms
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof denial-of-service attacks. The value should be increased if normal
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclients see an error response from the server that indicates too many
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfields were sent in the request.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limitrequestfieldsize">LimitRequestFieldsize directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt LimitRequestFieldsize} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> LimitRequestFieldsize <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LimitRequestFieldsize 8190</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> LimitRequestFieldsize is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.3.2 and later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<EM>Number</EM> is an integer size in bytes from 0 to the value of the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcompile-time constant <CODE>DEFAULT_LIMIT_REQUEST_FIELDSIZE</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl(8190 as distributed).
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe LimitRequestFieldsize directive allows the server administrator to reduce
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe limit on the allowed size of an HTTP request header field below the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnormal input buffer size compiled with the server. A server needs this
25cf1a301a396c38e8adf52c15f537b80d2483f7jlvalue to be large enough to hold any one header field from a normal client
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequest. The size of a normal request header field will vary greatly
25cf1a301a396c38e8adf52c15f537b80d2483f7jlamong different client implementations, often depending upon the extent
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto which a user has configured their browser to support detailed
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcontent negotiation.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive gives the server administrator greater control over abnormal
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclient request behavior, which may be useful for avoiding some forms
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof denial-of-service attacks. Under normal conditions, the value should
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnot be changed from the default.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="limitrequestline">LimitRequestLine directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt LimitRequestLine} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> LimitRequestLine <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LimitRequestLine 8190</CODE><BR>
e98fafb9956429b59c817d4fbd27720c73879203jl<A
e98fafb9956429b59c817d4fbd27720c73879203jl HREF="directive-dict.html#Context"
e98fafb9956429b59c817d4fbd27720c73879203jl REL="Help"
e98fafb9956429b59c817d4fbd27720c73879203jl><STRONG>Context:</STRONG></A> server config<BR>
e98fafb9956429b59c817d4fbd27720c73879203jl<A
e98fafb9956429b59c817d4fbd27720c73879203jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> LimitRequestLine is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.3.2 and later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
e98fafb9956429b59c817d4fbd27720c73879203jl<EM>Number</EM> is an integer size in bytes from 0 to the value of the
e98fafb9956429b59c817d4fbd27720c73879203jlcompile-time constant <CODE>DEFAULT_LIMIT_REQUEST_LINE</CODE>
e98fafb9956429b59c817d4fbd27720c73879203jl(8190 as distributed).
e98fafb9956429b59c817d4fbd27720c73879203jl<P>
e98fafb9956429b59c817d4fbd27720c73879203jl
e98fafb9956429b59c817d4fbd27720c73879203jlThe LimitRequestLine directive allows the server administrator to reduce
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe limit on the allowed size of a client's HTTP request-line below the
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywnormal input buffer size compiled with the server. Since the request-line
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywconsists of the HTTP method, URI, and protocol version, the
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywLimitRequestLine directive places a restriction on the length of a
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywrequest-URI allowed for a request on the server. A server needs this
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywvalue to be large enough to hold any of its resource names, including
f7832c8d6c8b1d0020951f2b254dca0a6a741824hywany information that might be passed in the query part of a GET request.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive gives the server administrator greater control over abnormal
25cf1a301a396c38e8adf52c15f537b80d2483f7jlclient request behavior, which may be useful for avoiding some forms
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof denial-of-service attacks. Under normal conditions, the value should
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnot be changed from the default.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="listen">Listen directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlListen [<EM>IP address</EM>:]<EM>port number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> Listen is only available in Apache
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.1 and later.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The Listen directive instructs Apache to listen to more than one IP
25cf1a301a396c38e8adf52c15f537b80d2483f7jladdress or port; by default it responds to requests on all IP
25cf1a301a396c38e8adf52c15f537b80d2483f7jlinterfaces, but only on the port given by the <CODE><A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#port">Port</A></CODE> directive.</P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<TT>Listen</TT> can be used instead of <TT><A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="#bindaddress">BindAddress</A></TT> and <TT>Port</TT>. It tells
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe server to accept incoming requests on the specified port or
25cf1a301a396c38e8adf52c15f537b80d2483f7jladdress-and-port combination. If the first format is used, with a port
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnumber only, the server listens to the given port on all interfaces,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlinstead of the port given by the <TT>Port</TT> directive. If an IP
25cf1a301a396c38e8adf52c15f537b80d2483f7jladdress is given as well as a port, the server will listen on the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlgiven port and interface. <P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote that you may still require a <TT>Port</TT> directive so
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthat URLs that Apache generates that point to your server still
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwork.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlMultiple Listen directives may be used
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto specify a number of addresses and ports to listen to. The server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlwill respond to requests from any of the listed addresses and
25cf1a301a396c38e8adf52c15f537b80d2483f7jlports.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlFor example, to make the server accept connections on both port
25cf1a301a396c38e8adf52c15f537b80d2483f7jl80 and port 8000, use:
2dd3029adb4864ebca3dd9cd6dad5fc4d38abff6jimand<PRE>
2dd3029adb4864ebca3dd9cd6dad5fc4d38abff6jimand Listen 80
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Listen 8000
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlTo make the server accept connections on two specified
25cf1a301a396c38e8adf52c15f537b80d2483f7jlinterfaces and port numbers, use
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Listen 192.170.2.1:80
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Listen 192.170.2.5:8000
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb</PRE>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P><STRONG>See Also:</STRONG>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A HREF="/dns-caveats.html">DNS Issues</A><BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<STRONG>See Also:</STRONG>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A HREF="/bind.html">Setting which addresses and ports Apache uses</A><BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<STRONG>See Also:</STRONG>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A HREF="http://www.apache.org/info/known_bugs.html#listenbug">Known Bugs</A>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb</P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<HR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<H2><A NAME="listenbacklog">ListenBacklog directive</A></H2>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Syntax"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Syntax:</STRONG></A> ListenBacklog <EM>backlog</EM><BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Default"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Default:</STRONG></A> <CODE>ListenBacklog 511</CODE><BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Context"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Context:</STRONG></A> server config<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Status"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Status:</STRONG></A> Core<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Compatibility"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Compatibility:</STRONG></A> ListenBacklog is only available in Apache
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbversions after 1.2.0.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>The maximum length of the queue of pending connections. Generally no
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbtuning is needed or desired, however on some systems it is desirable
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbto increase this when under a TCP SYN flood attack. See
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbthe backlog parameter to the <CODE>listen(2)</CODE> system call.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>This will often be limited to a smaller number by the operating
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbsystem. This varies from OS to OS. Also note that many OSes do not
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbuse exactly what is specified as the backlog, but use a number based on
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb(but normally larger than) what is set.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<HR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<H2><A NAME="location">&lt;Location&gt; directive</A></H2>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Syntax"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Syntax:</STRONG></A> &lt;Location <EM>URL</EM>&gt;
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb... &lt;/Location&gt;<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Context"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Context:</STRONG></A> server config, virtual host<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Status"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Status:</STRONG></A> core<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Compatibility"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Compatibility:</STRONG></A> Location is only available in Apache
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb1.1 and later.<P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>The &lt;Location&gt; directive provides for access control by
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbURL. It is similar to the <A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbHREF="#directory">&lt;Directory&gt;</A> directive, and
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbstarts a subsection which is terminated with a &lt;/Location&gt;
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbdirective. <CODE>&lt;Location&gt;</CODE> sections are processed in the
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmborder they appear in the configuration file, after the
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb&lt;Directory&gt; sections and <CODE>.htaccess</CODE> files are
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbread, and after the &lt;Files&gt; sections.</P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>Note that URLs do not have to line up with the filesystem at all,
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbit should be emphasized that &lt;Location&gt; operates completely outside
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbthe filesystem.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>For all origin (non-proxy) requests, the URL to be matched is
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbof the form <CODE>/path/</CODE>, and you should not include any
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<CODE>http://servername</CODE> prefix. For proxy requests, the URL
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbto be matched is of the form <CODE>scheme://servername/path</CODE>,
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmband you must include the prefix.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>The URL may use wildcards In a wild-card string, `?' matches any
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbsingle character, and `*' matches any sequences of characters.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P><STRONG>Apache 1.2 and above:</STRONG>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbExtended regular expressions can also be used, with the addition of
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbthe <CODE>~</CODE> character.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbFor example:</P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<PRE>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb &lt;Location ~ &quot;/(extra|special)/data&quot;&gt;
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb</PRE>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>would match URLs that contained the substring "/extra/data" or
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb"/special/data". In Apache 1.3 and above, a new directive
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A HREF="#locationmatch">&lt;LocationMatch&gt;</A> exists which
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbbehaves identical to the regex version of
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<CODE>&lt;Location&gt;</CODE>.
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>The <CODE>Location</CODE> functionality is especially useful when
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcombined with the <CODE><A
25cf1a301a396c38e8adf52c15f537b80d2483f7jlHREF="mod_mime.html#sethandler">SetHandler</A></CODE> directive. For example,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto enable status requests, but allow them only
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrom browsers at foo.com, you might use:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;Location /status&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl SetHandler server-status
25cf1a301a396c38e8adf52c15f537b80d2483f7jl order deny,allow
25cf1a301a396c38e8adf52c15f537b80d2483f7jl deny from all
25cf1a301a396c38e8adf52c15f537b80d2483f7jl allow from .foo.com
25cf1a301a396c38e8adf52c15f537b80d2483f7jl &lt;/Location&gt;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</PRE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>Apache 1.3 and above note about / (slash)</STRONG>: The slash
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcharacter has special
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmeaning depending on where in a URL it appears. People may be used
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto its behaviour in the filesystem where multiple adjacent slashes are
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfrequently collapsed to a single slash (<EM>i.e.</EM>, <CODE>/home///foo</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis the same as <CODE>/home/foo</CODE>). In URL-space this is not
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnecessarily true. The <CODE>&lt;LocationMatch&gt;</CODE> directive
25cf1a301a396c38e8adf52c15f537b80d2483f7jland the regex version of <CODE>&lt;Location&gt;</CODE> require you
25cf1a301a396c38e8adf52c15f537b80d2483f7jlto explicitly specify multiple slashes if that is your intention.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlFor example, <CODE>&lt;LocationMatch ^/abc&gt;</CODE> would match the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequest URL <CODE>/abc</CODE> but not the request URL <CODE>//abc</CODE>.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe (non-regex) <CODE>&lt;Location&gt;</CODE> directive behaves
25cf1a301a396c38e8adf52c15f537b80d2483f7jlsimilarly when used for proxy requests. But when (non-regex)
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>&lt;Location&gt;</CODE> is used for non-proxy requests it will
25cf1a301a396c38e8adf52c15f537b80d2483f7jlimplicitly match multiple slashes with a single slash. For example,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlif you specify <CODE>&lt;Location /abc/def&gt;</CODE> and the request
25cf1a301a396c38e8adf52c15f537b80d2483f7jlis to <CODE>/abc//def</CODE> then it will match.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jlLocation and Files sections work</A> for an explanation of how these
25cf1a301a396c38e8adf52c15f537b80d2483f7jldifferent sections are combined when a request is received
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<H2><A NAME="locationmatch">&lt;LocationMatch&gt;</A></H2>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Syntax"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Syntax:</STRONG></A> &lt;LocationMatch <EM>regex</EM>&gt;
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb... &lt;/LocationMatch&gt;<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Context"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Context:</STRONG></A> server config, virtual host<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Status"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Status:</STRONG></A> core<BR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb HREF="directive-dict.html#Compatibility"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb REL="Help"
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb><STRONG>Compatibility:</STRONG></A> LocationMatch is only available in
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbApache 1.3 and later.<P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>The &lt;LocationMatch&gt; directive provides for access control by
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbURL, in an identical manner to <A
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbHREF="#location">&lt;Location&gt;</A>. However, it takes a regular
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbexpression as an argument instead of a simple string. For example:</P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<PRE>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb &lt;LocationMatch &quot;/(extra|special)/data&quot;&gt;
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb</PRE>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<P>would match URLs that contained the substring "/extra/data" or
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb"/special/data".</P>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbLocation and Files sections work</A> for an explanation of how these
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmbdifferent sections are combined when a request is received
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<HR>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<H2><A NAME="lockfile">LockFile directive</A></H2>
50eff7691a80815571befbb7c9fe5f0bbf22dcbdmb<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> LockFile <EM>filename</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LockFile logs/accept.lock</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe LockFile directive sets the path to the lockfile used when
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache is compiled with either USE_FCNTL_SERIALIZED_ACCEPT or
25cf1a301a396c38e8adf52c15f537b80d2483f7jlUSE_FLOCK_SERIALIZED_ACCEPT. This directive should normally be
25cf1a301a396c38e8adf52c15f537b80d2483f7jlleft at its default value. The main reason for changing it is if
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe <CODE>logs</CODE> directory is NFS mounted, since <STRONG>the lockfile
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmust be stored on a local disk</STRONG>. The PID of the main
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver process is automatically appended to the filename. <P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>SECURITY:</STRONG> It is best to avoid putting this file in a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlworld writable directory such as <CODE>/var/tmp</CODE> because someone
25cf1a301a396c38e8adf52c15f537b80d2483f7jlcould create a denial of service attack and prevent the server from
25cf1a301a396c38e8adf52c15f537b80d2483f7jlstarting by creating a lockfile with the same name as the one the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlserver will try to create.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="loglevel">LogLevel directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> LogLevel <EM>level</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>LogLevel error</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> LogLevel is only available in 1.3 or
25cf1a301a396c38e8adf52c15f537b80d2483f7jllater.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>LogLevel adjusts the verbosity of the messages recorded in the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlerror logs (see <A HREF="#errorlog">ErrorLog</A> directive).
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe following <EM>level</EM>s are available, in order of
25cf1a301a396c38e8adf52c15f537b80d2483f7jldecreasing significance:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><TABLE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TH ALIGN="LEFT"><STRONG>Level</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TH ALIGN="LEFT"><STRONG>Description</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TH><TH ALIGN="LEFT"><STRONG>Example</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>emerg</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Emergencies - system is unusable.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"Child cannot open lock file. Exiting"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>alert</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Action must be taken immediately.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"getpwuid: couldn't determine user name from uid"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>crit</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Critical Conditions.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"socket: Failed to get a socket, exiting child"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>error</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Error conditions.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"Premature end of script headers"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>warn</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Warning conditions.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"child process 1234 did not exit, sending another SIGHUP"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>notice</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Normal but significant condition.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"httpd: caught SIGBUS, attempting to dump core in ..."
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>info</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Informational.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"Server seems busy, (you may need to increase StartServers, or
25cf1a301a396c38e8adf52c15f537b80d2483f7jl Min/MaxSpareServers)..."
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><CODE>debug</CODE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TD>Debug-level messages
25cf1a301a396c38e8adf52c15f537b80d2483f7jl <TR><TD><TD>"Opening config file ..."
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</TABLE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>When a particular level is specified, messages from all other levels
25cf1a301a396c38e8adf52c15f537b80d2483f7jlof higher significance will be reported as well. <EM>E.g.</EM>, when
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>LogLevel info</CODE> is specified, then messages with log levels of
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<CODE>notice</CODE> and <CODE>warn</CODE> will also be posted.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlUsing a level of at least <CODE>crit</CODE> is recommended.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="maxclients">MaxClients directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt MaxClients} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> MaxClients <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>MaxClients 256</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
f7832c8d6c8b1d0020951f2b254dca0a6a741824hyw REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The MaxClients directive sets the limit on the number of simultaneous
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequests that can be supported; not more than this number of child server
25cf1a301a396c38e8adf52c15f537b80d2483f7jlprocesses will be created. To configure more than 256 clients, you must
25cf1a301a396c38e8adf52c15f537b80d2483f7jledit the HARD_SERVER_LIMIT entry in httpd.h and recompile.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>Any connection attempts over the MaxClients limit will normally
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbe queued, up to a number based on the <A HREF="#listenbacklog">
25cf1a301a396c38e8adf52c15f537b80d2483f7jlListenBacklog</A> directive. Once a child process is freed at the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlend of a different request, the connection will then be serviced.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="maxkeepaliverequests">MaxKeepAliveRequests directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> MaxKeepAliveRequests <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>MaxKeepAliveRequests 100</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> Only available in Apache
25cf1a301a396c38e8adf52c15f537b80d2483f7jl1.2 and later.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>The MaxKeepAliveRequests directive limits the number of requests
25cf1a301a396c38e8adf52c15f537b80d2483f7jlallowed per connection when <A HREF="#keepalive">KeepAlive</A> is
25cf1a301a396c38e8adf52c15f537b80d2483f7jlon. If it is set to "<CODE>0</CODE>", unlimited requests will be
25cf1a301a396c38e8adf52c15f537b80d2483f7jlallowed. We recommend that this setting be kept to a high value for
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmaximum server performance.</P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="maxrequestsperchild">MaxRequestsPerChild directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt MaxRequestsPerChild} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> MaxRequestsPerChild <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>MaxRequestsPerChild 0</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe MaxRequestsPerChild directive sets the limit on the number of requests
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthat an individual child server process will handle. After MaxRequestsPerChild
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequests, the child process will die. If MaxRequestsPerChild is 0, then
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe process will never expire.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSetting MaxRequestsPerChild to a non-zero limit has two beneficial effects:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI>it limits the amount of memory that process can consume by (accidental)
25cf1a301a396c38e8adf52c15f537b80d2483f7jlmemory leakage;
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<LI> by giving processes a finite lifetime, it helps reduce the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlnumber of processes when the server load reduces.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl</UL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>This directive has no effect on Win32.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><STRONG>NOTE:</STRONG> For <EM>KeepAlive</EM> requests, only the first
25cf1a301a396c38e8adf52c15f537b80d2483f7jlrequest is counted towards this limit. In effect, it changes the
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbehavior to limit the number of <EM>connections</EM> per child.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="maxspareservers">MaxSpareServers directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt MaxSpareServers} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> MaxSpareServers <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>MaxSpareServers 10</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson><STRONG>Status:</STRONG></A> core<P>
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James AndersonThe MaxSpareServers directive sets the desired maximum number of <EM>idle</EM>
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Andersonchild server processes. An idle process is one which is not handling
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Andersona request. If there are more than MaxSpareServers idle, then the parent
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Andersonprocess will kill off the excess processes.<P>
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James AndersonTuning of this parameter should only be necessary on very busy sites.
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James AndersonSetting this parameter to a large number is almost always a bad idea.<P>
c9d93b537520c235a6d4a0af53b9bf07cf3390e9James Anderson
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive has no effect when used with the Apache Web server on a
25cf1a301a396c38e8adf52c15f537b80d2483f7jlMicrosoft Windows platform.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSee also <A HREF="#minspareservers">MinSpareServers</A> and
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#startservers">StartServers</A>.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="minspareservers">MinSpareServers directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt MinSpareServers} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> MinSpareServers <EM>number</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Default"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Default:</STRONG></A> <CODE>MinSpareServers 5</CODE><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe MinSpareServers directive sets the desired minimum number of <EM>idle</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlchild server processes. An idle process is one which is not handling
25cf1a301a396c38e8adf52c15f537b80d2483f7jla request. If there are fewer than MinSpareServers idle, then the parent
25cf1a301a396c38e8adf52c15f537b80d2483f7jlprocess creates new children at a maximum rate of 1 per second.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlTuning of this parameter should only be necessary on very busy sites.
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSetting this parameter to a large number is almost always a bad idea.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThis directive has no effect on Microsoft Windows.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlSee also <A HREF="#maxspareservers">MaxSpareServers</A> and
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="#startservers">StartServers</A>.<P><HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="namevirtualhost">NameVirtualHost directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt NameVirtualHost} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> NameVirtualHost <EM>addr</EM>[:<EM>port</EM>]<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Compatibility"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Compatibility:</STRONG></A> NameVirtualHost is only available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jlApache 1.3 and later<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe NameVirtualHost directive is a required directive if you want to configure
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/vhosts/index.html">name-based virtual hosts</A>.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlAlthough <EM>addr</EM> can be hostname it is recommended that you always use
25cf1a301a396c38e8adf52c15f537b80d2483f7jlan IP address, <EM>e.g.</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>NameVirtualHost 111.22.33.44</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlWith the NameVirtualHost directive you specify the address to which your
25cf1a301a396c38e8adf52c15f537b80d2483f7jlname-based virtual host names resolve. If you have multiple name-based
25cf1a301a396c38e8adf52c15f537b80d2483f7jlhosts on multiple addresses, repeat the directive for each address.<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlNote: the "main server" and any _default_ servers will <STRONG>never</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jlbe served for a request to a NameVirtualHost IP Address (unless for some
25cf1a301a396c38e8adf52c15f537b80d2483f7jlreason you specify NameVirtualHost but then don't define any VirtualHosts
25cf1a301a396c38e8adf52c15f537b80d2483f7jlfor that address).<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlOptionally you can specify a port number on which the name-based
25cf1a301a396c38e8adf52c15f537b80d2483f7jlvirtual hosts should be used, <EM>e.g.</EM>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<BLOCKQUOTE><CODE>NameVirtualHost 111.22.33.44:8080</CODE></BLOCKQUOTE>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<STRONG>See also:</STRONG>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A HREF="/vhosts/index.html">Apache Virtual Host documentation</A>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<HR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<H2><A NAME="options">Options directive</A></H2>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<!--%plaintext &lt;?INDEX {\tt Options} directive&gt; -->
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Syntax"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Syntax:</STRONG></A> Options <EM>[+|-]option [+|-]option ...</EM><BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Context"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Context:</STRONG></A> server config, virtual host, directory,
25cf1a301a396c38e8adf52c15f537b80d2483f7jl.htaccess<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Override"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Override:</STRONG></A> Options<BR>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<A
25cf1a301a396c38e8adf52c15f537b80d2483f7jl HREF="directive-dict.html#Status"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl REL="Help"
25cf1a301a396c38e8adf52c15f537b80d2483f7jl><STRONG>Status:</STRONG></A> core<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl
25cf1a301a396c38e8adf52c15f537b80d2483f7jlThe Options directive controls which server features are available in
25cf1a301a396c38e8adf52c15f537b80d2483f7jla particular directory.
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<P>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<EM>option</EM> can be set to <CODE>None</CODE>, in which case none of
25cf1a301a396c38e8adf52c15f537b80d2483f7jlthe extra features are enabled, or one or more of the following:
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DL>
25cf1a301a396c38e8adf52c15f537b80d2483f7jl<DT>All
<DD>All options except for MultiViews. This is the default setting.
<DT>ExecCGI
<DD>
<!--%plaintext &lt;?INDEX {\tt ExecCGI} option&gt; -->
Execution of CGI scripts is permitted.
<DT>FollowSymLinks
<DD>
<!--%plaintext &lt;?INDEX {\tt FollowSymLinks} option&gt; -->
The server will follow symbolic links in this directory.
<BR>
<STRONG>Note</STRONG>: even though the server follows the symlink it
does <EM>not</EM>
change the pathname used to match against <CODE>&lt;Directory&gt;</CODE>
sections.
<BR>
<STRONG>Note</STRONG>: this option gets ignored if set inside a
&lt;Location&gt; section.
<DT>Includes
<DD>
<!--%plaintext &lt;?INDEX {\tt Includes} option&gt; -->
Server-side includes are permitted.
<DT>IncludesNOEXEC
<DD>
<!--%plaintext &lt;?INDEX {\tt IncludesNOEXEC} option&gt; -->
Server-side includes are permitted, but the #exec command and
#include of CGI scripts are disabled.
<DT>Indexes
<DD>
<!--%plaintext &lt;?INDEX {\tt Indexes} option&gt; -->
If a URL which maps to a directory is requested, and the there is no
DirectoryIndex (<EM>e.g.</EM>, index.html) in that directory, then the server will
return a formatted listing of the directory.
<DT>MultiViews
<DD>
<!--%plaintext &lt;?INDEX {\tt MultiViews} option&gt; -->
<A HREF="/content-negotiation.html">Content negotiated</A> MultiViews are
allowed.
<DT>SymLinksIfOwnerMatch
<DD>
<!--%plaintext &lt;?INDEX {\tt SymLinksIfOwnerMatch} option&gt; -->
The server will only follow symbolic links for which the target
file or directory is owned by the same user id as the link.
<BR>
<STRONG>Note</STRONG>: this option gets ignored if set inside a
&lt;Location&gt; section.
</DL>
Normally, if multiple <CODE>Options</CODE> could apply to a directory,
then the most specific one is taken complete; the options are not
merged. However if <EM>all</EM> the options on the <CODE>Options</CODE>
directive are preceded by a + or - symbol, the options are
merged. Any options preceded by a + are added to the options
currently in force, and any options preceded by a - are removed from
the options currently in force. <P>
For example, without any + and - symbols:
<BLOCKQUOTE><CODE>
&lt;Directory /web/docs&gt; <BR>
Options Indexes FollowSymLinks<BR>
&lt;/Directory&gt;<BR>
&lt;Directory /web/docs/spec&gt; <BR>
Options Includes<BR>
&lt;/Directory&gt;
</CODE></BLOCKQUOTE>
then only <CODE>Includes</CODE> will be set for the /web/docs/spec
directory. However if the second <CODE>Options</CODE> directive uses the +
and - symbols:<P>
<BLOCKQUOTE><CODE>
&lt;Directory /web/docs&gt; <BR>
Options Indexes FollowSymLinks<BR>
&lt;/Directory&gt;<BR>
&lt;Directory /web/docs/spec&gt; <BR>
Options +Includes -Indexes<BR>
&lt;/Directory&gt;
</CODE></BLOCKQUOTE>
then the options <CODE>FollowSymLinks</CODE> and <CODE>Includes</CODE>
are set for the /web/docs/spec directory.<P>
<STRONG>Note:</STRONG> Using <CODE>-IncludesNOEXEC</CODE> or
<CODE>-Includes</CODE>
disables server-side includes completely regardless of the previous setting.<P>
The default in the absence of any other settings is <CODE>All</CODE>.<P>
<HR>
<H2><A NAME="pidfile">PidFile directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt PidFile} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> PidFile <EM>filename</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>PidFile logs/httpd.pid</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The PidFile directive sets the file to which the server records the
process id of the daemon. If the filename does not begin with a slash (/)
then it is assumed to be relative to the <A HREF="#serverroot">ServerRoot</A>.
The PidFile is only used in <A HREF="#servertype">standalone</A> mode.<P>
It is often useful to be able to send the server a signal, so that it closes
and then reopens its <A HREF="#errorlog">ErrorLog</A> and TransferLog, and
re-reads its configuration files. This is done by sending a SIGHUP (kill -1)
signal to the process id listed in the PidFile.<P>
The PidFile is subject to the same warnings about log file placement and
<A HREF="/misc/security_tips.html#serverroot">security</A>.
<P><HR>
<H2><A NAME="port">Port directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt Port} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> Port <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>Port 80</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
<EM>Number</EM> is a number from 0 to 65535; some port numbers
(especially below
1024) are reserved for particular protocols. See <CODE>/etc/services</CODE>
for a list of some defined ports; the standard port for the http protocol
is 80.<P>
The Port directive has two behaviors, the first of which is necessary for
NCSA backwards compatibility (and which is confusing in the context of
Apache).<P>
<UL>
<LI>
In the absence of any <A HREF="#listen">Listen</A> or
<A HREF="#bindaddress">BindAddress</A> directives specifying a port number,
a Port directive given in the "main server"
(<EM>i.e.</EM>, outside any <A HREF="#virtualhost">&lt;VirtualHost&gt</A> section)
sets the network port on which the server listens.
If there are any Listen or BindAddress directives specifying
<CODE>:number</CODE> then Port has no effect on what address the server
listens at.
<LI>The Port directive
sets the <CODE>SERVER_PORT</CODE> environment variable (for
<A HREF="mod_cgi.html">CGI</A> and <A HREF="mod_include.html">SSI</A>),
and is used when the server must generate a URL that refers to itself
(for example when creating an external redirect to itself). This
behaviour is modified by
<A HREF="#usecanonicalname">UseCanonicalName</A>.
</UL>
In no event does a Port setting affect
what ports a <A HREF="#virtualhost">VirtualHost</A> responds on, the
VirtualHost directive itself is used for that.<P>
The primary behaviour of Port should be considered to be similar to that of
the <A HREF="#servername">ServerName</A> directive. The ServerName
and Port together specify what you consider to be the <EM>canonical</EM>
address of the server.
(See also <A HREF="#usecanonicalname">UseCanonicalName</A>.)<P>
Port 80 is one of Unix's special ports. All ports numbered
below 1024 are reserved for system use, <EM>i.e.</EM>, regular (non-root) users cannot
make use of them; instead they can only use higher port numbers.
To use port 80, you must start the server from the root account.
After binding to the port and before accepting requests, Apache will change
to a low privileged user as set by the <A HREF="#user">User directive</A>.<P>
If you cannot use port 80, choose any other unused port. Non-root users
will have to choose a port number higher than 1023, such as 8000.<P>
SECURITY: if you do start the server as root, be sure
not to set <A HREF="#user">User</A> to root. If you run the server as
root whilst handling connections, your site may be open to a major security
attack.<P><HR>
<H2><A NAME="require">require directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt require} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> require <EM>entity-name entity entity...</EM><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
<A
HREF="directive-dict.html#Override"
REL="Help"
><STRONG>Override:</STRONG></A> AuthConfig<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
This directive selects which authenticated users can access a directory.
The allowed syntaxes are:
<UL>
<LI>require user <EM>userid userid ...</EM><P>
Only the named users can access the directory.<P>
<LI>require group <EM>group-name group-name ...</EM><P>
Only users in the named groups can access the directory.<P>
<LI>require valid-user<P>
All valid users can access the directory.
</UL>
<P>
Require must be accompanied by <A HREF="#authname">AuthName</A> and
<A HREF="#authtype">AuthType</A> directives, and directives such as
<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> (to define users and
groups) in order to work correctly. Example:
<BLOCKQUOTE><CODE>
AuthType Basic<BR>
AuthName "Restricted Directory"<BR>
AuthUserFile /web/users<BR>
AuthGroupFile /web/groups<BR>
require group admin<BR>
</CODE></BLOCKQUOTE>
Access controls which are applied in this way are effective for
<STRONG>all</STRONG> methods. <STRONG>This is what is normally
desired.</STRONG> If you wish to apply access controls only to
specific methods, while leaving other methods unprotected, then place
the <CODE>require</CODE> statement into a <A
HREF="#limit">&lt;Limit&gt;</A> section<P><HR>
<H2><A NAME="resourceconfig">ResourceConfig directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ResourceConfig} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ResourceConfig <EM>filename</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ResourceConfig conf/srm.conf</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The server will read this file for more directives after reading the
httpd.conf file. <EM>Filename</EM> is relative to the
<A HREF="#serverroot">ServerRoot</A>.
This feature can be disabled using:
<BLOCKQUOTE><CODE>ResourceConfig /dev/null</CODE></BLOCKQUOTE>
Historically, this file contained most directives except for server
configuration directives and <A HREF="#directory">&lt;Directory&gt;</A>
sections; in fact it can now contain any server directive allowed in the
<EM>server config</EM> context.<P>
See also <A HREF="#accessconfig">AccessConfig</A>.<P><HR>
<H2><A NAME="rlimit">RLimitCPU</A> <A NAME="rlimitcpu">directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt RLimitCPU} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> RLimitCPU <EM># or 'max'</EM>
<EM>[# or 'max']</EM>
<BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <EM>Unset; uses operating system defaults</EM>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> RLimitCPU is only available in Apache 1.2
and later<P>
Takes 1 or 2 parameters. The first parameter sets the soft resource limit
for all processes and the second parameter sets the maximum resource limit.
Either parameter can be a number, or <EM>max</EM> to indicate to the server
that the limit should be set to the maximum allowed by the operating system
configuration. Raising the maximum resource limit requires that the server
is running as root, or in the initial startup phase.<P>
This applies to processes forked off from Apache children servicing requests,
not the Apache children themselves. This includes CGI scripts and SSI
exec commands, but not any processes forked off from the Apache parent
such as piped logs.<P>
CPU resource limits are expressed in seconds per process.<P>
See also <A HREF="#rlimitmem">RLimitMEM</A> or
<A HREF="#rlimitnproc">RLimitNPROC</A>.<P><HR>
<H2><A NAME="rlimitmem">RLimitMEM directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt RLimitMEM} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> RLimitMEM <EM># or 'max'</EM>
<EM>[# or 'max']</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <EM>Unset; uses operating system defaults</EM>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> RLimitMEM is only available in Apache 1.2
and later<P>
Takes 1 or 2 parameters. The first parameter sets the soft resource limit for
all processes and the second parameter sets the maximum resource limit. Either
parameter can be a number, or <EM>max</EM> to indicate to the server that the
limit should be set to the maximum allowed by the operating system
configuration. Raising the maximum resource limit requires that the
server is running as root, or in the initial startup phase.<P>
This applies to processes forked off from Apache children servicing requests,
not the Apache children themselves. This includes CGI scripts and SSI
exec commands, but not any processes forked off from the Apache parent
such as piped logs.<P>
Memory resource limits are expressed in bytes per process.<P>
See also <A HREF="#rlimitcpu">RLimitCPU</A> or
<A HREF="#rlimitnproc">RLimitNPROC</A>.<P><HR>
<H2><A NAME="rlimitnproc">RLimitNPROC directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt RLimitNPROC} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> RLimitNPROC <EM># or 'max'</EM>
<EM>[# or 'max']</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <EM>Unset; uses operating system defaults</EM>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> RLimitNPROC is only available in Apache
1.2 and later<P>
Takes 1 or 2 parameters. The first parameter sets the soft resource limit
for all processes and the second parameter sets the maximum resource limit.
Either parameter can be a number, or <EM>max</EM> to indicate to the server
that the limit should be set to the maximum allowed by the operating system
configuration. Raising the maximum resource limit requires that the server
is running as root, or in the initial startup phase.<P>
This applies to processes forked off from Apache children servicing requests,
not the Apache children themselves. This includes CGI scripts and SSI
exec commands, but not any processes forked off from the Apache parent
such as piped logs.<P>
Process limits control the number of processes per user.<P>
Note: If CGI processes are <STRONG>not</STRONG> running under userids other
than the
web server userid, this directive will limit the number of processes that the
server itself can create. Evidence of this situation will be indicated by
<STRONG><EM>cannot fork</EM></STRONG> messages in the error_log.<P>
See also <A HREF="#rlimitmem">RLimitMEM</A> or
<A HREF="#rlimitcpu">RLimitCPU</A>.
<P><HR>
<H2><A NAME="satisfy">Satisfy directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt Satisfy} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> Satisfy <EM>'any' or 'all'</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> Satisfy all<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Satisfy is only available in Apache 1.2
and later<P>
Access policy if both allow and require used. The parameter can be
either <EM>'all'</EM> or <EM>'any'</EM>. This directive is only useful
if access to a particular area is being restricted by both
username/password <EM>and</EM> client host address. In this case the
default behavior ("all") is to require that the client passes the
address access restriction <EM>and</EM> enters a valid username and
password. With the "any" option the client will be granted access if
they either pass the host restriction or enter a valid username and
password. This can be used to password restrict an area, but to let
clients from particular addresses in without prompting for a password.
<P><HR>
<H2><A NAME="scoreboardfile">ScoreBoardFile directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ScoreBoardFile} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ScoreBoardFile <EM>filename</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ScoreBoardFile logs/apache_status</CODE>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The ScoreBoardFile directive is required on some architectures to place
a file that the server will use to communicate between its children and
the parent. The easiest way to find out if your architecture requires
a scoreboard file is to run Apache and see if it creates the file named
by the directive. If your architecture requires it then you must ensure
that this file is not used at the same time by more than one invocation
of Apache.<P>
If you have to use a ScoreBoardFile then you may see improved speed by
placing it on a RAM disk. But be careful that you heed the same warnings
about log file placement and
<A HREF="/misc/security_tips.html">security</A>.<P>
Apache 1.2 and above:<P>
Linux 1.x users might be able to add
<CODE>-DHAVE_SHMGET -DUSE_SHMGET_SCOREBOARD</CODE> to
the <CODE>EXTRA_CFLAGS</CODE> in your <CODE>Configuration</CODE>. This
might work with some 1.x installations, but won't work with all of
them. (Prior to 1.3b4, <CODE>HAVE_SHMGET</CODE> would have sufficed.)<P>
SVR4 users should consider adding
<CODE>-DHAVE_SHMGET -DUSE_SHMGET_SCOREBOARD</CODE> to the
<CODE>EXTRA_CFLAGS</CODE> in your <CODE>Configuration</CODE>. This
is believed to work, but we were unable to test it in time for 1.2
release. (Prior to 1.3b4, <CODE>HAVE_SHMGET</CODE> would have sufficed.)<P>
<STRONG>See Also</STRONG>:
<A HREF="/stopping.html">Stopping and Restarting Apache</A></P>
<P><HR>
<H2><A NAME="scriptinterpretersource">ScriptInterpreterSource directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ScriptInterpreterSource} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ScriptInterpreterSource <EM>'registry' or 'script'</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ScriptInterpreterSource script</CODE>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core (Windows only)<P>
This directive is used to control how Apache 1.3.5 and later finds the interpreter
used to run CGI scripts. The default technique is to use the interpreter pointed to by
the #! line in the script. Setting ScriptInterpreterSource registry will cause the
Windows Registry to be searched using the script file extension (e.g., .pl) as a search key.
<P><HR>
<H2><A NAME="sendbuffersize">SendBufferSize directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt SendBufferSize} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> SendBufferSize <EM>bytes</EM><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The server will set the TCP buffer size to the number of bytes
specified. Very useful to increase past standard OS defaults on high
speed high latency (<EM>i.e.</EM>, 100ms or so, such as transcontinental
fast pipes)
<P><HR>
<H2><A NAME="serveradmin">ServerAdmin directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerAdmin} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerAdmin <EM>email-address</EM><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The ServerAdmin sets the e-mail address that the server includes in any
error messages it returns to the client.<P>
It may be worth setting up a dedicated address for this, <EM>e.g.</EM>
<BLOCKQUOTE><CODE>ServerAdmin www-admin@foo.bar.com</CODE></BLOCKQUOTE>
as users do not always mention that they are talking about the server!<P><HR>
<H2><A NAME="serveralias">ServerAlias directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerAlias <EM>host1 host2 ...</EM><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> ServerAlias is only available in Apache
1.1 and later.<P>
The ServerAlias directive sets the alternate names for a host, for use
with
<A HREF="/vhosts/name-based.html">name-based virtual hosts</A>.
<P><STRONG>See also:</STRONG>
<A HREF="/vhosts/index.html">Apache Virtual Host documentation</A>
<HR>
<H2><A NAME="servername">ServerName directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerName} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerName <EM>fully-qualified domain name</EM>
<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The ServerName directive sets the hostname of the server; this is
used when creating redirection URLs. If it is not specified, then the
server attempts to deduce it from its own IP address; however this may
not work reliably, or may not return the preferred hostname. For example:
<BLOCKQUOTE><CODE>ServerName www.example.com</CODE></BLOCKQUOTE>
would be used if the canonical (main) name of the actual machine
were <CODE>simple.example.com</CODE>.<P>
If you are using <A HREF="/vhosts/name-based.html">name-based
virtual hosts</A>, the <CODE>ServerName</CODE> inside a
<A HREF="#virtualhost"><CODE>&lt;VirtualHost&gt;</CODE></A>
section specifies what hostname must appear in the request's
<CODE>Host:</CODE> header to match this virtual host.<P>
<P><STRONG>See Also</STRONG>:<BR>
<A HREF="/dns-caveats.html">DNS Issues</A><BR>
<A HREF="/vhosts/index.html">Apache virtual host documentation</A><BR>
<A HREF="#usecanonicalname">UseCanonicalName</A><BR>
<A HREF="#namevirtualhost">NameVirtualHost</A><BR>
<A HREF="#serveralias">ServerAlias</A><BR>
</P>
<HR>
<H2><A NAME="serverpath">ServerPath directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerPath <EM>pathname</EM><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> ServerPath is only available in Apache
1.1 and later.<P>
The ServerPath directive sets the legacy URL pathname for a host, for
use with <A HREF="/vhosts/index.html">name-based virtual hosts</A>.
<P><STRONG>See also:</STRONG>
<A HREF="/vhosts/index.html">Apache Virtual Host documentation</A>
<HR>
<H2><A NAME="serverroot">ServerRoot directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerRoot} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerRoot <EM>directory-filename</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ServerRoot /usr/local/apache</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The ServerRoot directive sets the directory in which the server lives.
Typically it will contain the subdirectories <CODE>conf/</CODE> and
<CODE>logs/</CODE>. Relative paths for other configuration files are taken
as relative to this directory.<P>
See also <A HREF="/invoking.html">the <CODE>-d</CODE> option to httpd</A>.<P>
See also <A HREF="/misc/security_tips.html#serverroot">the security tips</A>
for information on how to properly set permissions on the ServerRoot.<P>
<HR>
<H2><A NAME="serversignature">ServerSignature directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerSignature} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerSignature <EM>Off | On | EMail</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ServerSignature Off</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host, directory,
.htaccess<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> ServerSignature is only available in
Apache
1.3 and later.<P>
The ServerSignature directive allows the configuration of a trailing
footer line under server-generated documents (error messages,
mod_proxy ftp directory listings, mod_info output, ...). The reason
why you would want to enable such a footer line is that in a chain
of proxies, the user often has no possibility to tell which of the
chained servers actually produced a returned error message.<BR>
The <SAMP>Off</SAMP> setting, which is the default, suppresses the
error line (and is therefore compatible with the behavior of
Apache-1.2 and below). The <SAMP>On</SAMP> setting simply adds a
line with the server version number and <A
HREF="#servername">ServerName</A> of the serving virtual host, and
the <SAMP>EMail</SAMP> setting additionally creates a "mailto:"
reference to the <A HREF="#serveradmin">ServerAdmin</A> of the
referenced document.
<HR>
<H2><A NAME="servertokens">ServerTokens directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerTokens} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerTokens <EM>Minimal|OS|Full</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ServerTokens Full</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config <BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> ServerTokens is only available
in Apache 1.3 and later
<P>
This directive controls whether <SAMP>Server</SAMP> response header
field which is sent back to clients includes a description of the generic
OS-type of the server as well as information about compiled-in modules.
</P>
<DL>
<DT><CODE>ServerTokens Min[imal]</CODE>
</DT>
<DD>Server sends (<EM>e.g.</EM>): <SAMP>Server: Apache/1.3.0</SAMP>
</DD>
<DT><CODE>ServerTokens OS</CODE>
</DT>
<DD>Server sends (<EM>e.g.</EM>): <SAMP>Server: Apache/1.3.0 (Unix)</SAMP>
</DD>
<DT><CODE>ServerTokens Full</CODE> (or not specified)
</DT>
<DD>Server sends (<EM>e.g.</EM>): <SAMP>Server: Apache/1.3.0 (Unix) PHP/3.0
MyMod/1.2</SAMP>
</DD>
</DL>
<P>
This setting applies to the entire server, and cannot be enabled or
disabled on a virtualhost-by-virtualhost basis.
</P>
<HR>
<H2><A NAME="servertype">ServerType directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt ServerType} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ServerType <EM>type</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ServerType standalone</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The ServerType directive sets how the server is executed by the system.
<EM>Type</EM> is one of
<DL>
<DT>inetd
<DD>The server will be run from the system process inetd; the command to start
the server is added to <CODE>/etc/inetd.conf</CODE>
<DT>standalone
<DD>The server will run as a daemon process; the command to start the server
is added to the system startup scripts. (<CODE>/etc/rc.local</CODE> or
<CODE>/etc/rc3.d/...</CODE>.)
</DL>
Inetd is the lesser used of the two options. For each http
connection received, a new copy of the server is started from scratch;
after the connection is complete, this program exits. There is a high price to
pay per connection, but for security reasons, some admins prefer this option.
<FONT COLOR="red">Inetd mode is no longer recommended and does not always
work properly. Avoid it if at all possible.</FONT>
<P>
Standalone is the most common setting for ServerType since
it is far more efficient. The server is started once, and services all
subsequent connections. If you intend running Apache to serve a busy site,
standalone will probably be your only option.<P>
<HR>
<H2><A NAME="startservers">StartServers directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt StartServers} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> StartServers <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>StartServers 5</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The StartServers directive sets the number of child server processes created
on startup. As the number of processes is dynamically controlled depending
on the load, there is usually little reason to adjust this parameter.<P>
<P>When running under Microsoft Windows, this directive has no effect.
There is always one child which handles all requests. Within the
child requests are handled by separate threads. The
<A HREF="#threadsperchild">ThreadsPerChild</A> directive controls
the maximum number of child threads handling requests, which will
have a similar effect to the setting of <SAMP>StartServers</SAMP>
on Unix.
<P>
See also <A HREF="#minspareservers">MinSpareServers</A> and
<A HREF="#maxspareservers">MaxSpareServers</A>.<P><HR>
<H2><A NAME="threadsperchild">ThreadsPerChild</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ThreadsPerChild <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ThreadsPerChild 50</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core (Windows)<BR>
<STRONG>Compatibility:</STRONG> Available only with Apache 1.3 and later
with Windows
<P>This directive tells the server how many threads it should use. This
is the maximum number of connections the server can handle at once; be
sure and set this number high enough for your site if you get a lot of
hits.
<P>This directive has no effect on Unix systems. Unix users should look
at <A HREF="#startservers">StartServers</A> and <A
HREF="#maxrequestsperchild">MaxRequestsPerChild</A>.</P>
<HR>
<H2><A NAME="timeout">TimeOut directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt TimeOut} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> TimeOut <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>TimeOut 300</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The TimeOut directive currently defines the amount of time Apache will
wait for three things:
<OL>
<LI>The total amount of time it takes to receive a GET request.
<LI>The amount of time between receipt of TCP packets on a POST or
PUT request.
<LI>The amount of time between ACKs on transmissions of TCP packets
in responses.
</OL>
We plan on making these separately configurable at some point down the
road. The timer used to default to 1200 before 1.2, but has been
lowered to 300 which is still far more than necessary in most
situations. It is not set any lower by default because there may
still be odd places in the code where the timer is not reset when
a packet is sent.
<P><HR>
<H2><A NAME="usecanonicalname">UseCanonicalName directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt UseCanonicalName} directive&gt; -->
<A HREF="directive-dict.html#Syntax" REL="Help">
<STRONG>Syntax:</STRONG></A> UseCanonicalName <EM>on|off|dns</EM><BR>
<A HREF="directive-dict.html#Default" REL="Help">
<STRONG>Default:</STRONG></A> <CODE>UseCanonicalName on</CODE><BR>
<A HREF="directive-dict.html#Context" REL="Help">
<STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A HREF="directive-dict.html#Override" REL="Help">
<STRONG>Override:</STRONG></A> Options<BR>
<A HREF="directive-dict.html#Compatibility" REL="Help">
<STRONG>Compatibility:</STRONG></A> UseCanonicalName is only available in
Apache 1.3 and later<P>
In many situations Apache has to construct a <EM>self-referential</EM>
URL. That is, a URL which refers back to the same server.
With <CODE>UseCanonicalName on</CODE> (and in all versions prior to
1.3) Apache will use the <A HREF="#servername">ServerName</A> and <A
HREF="#port">Port</A> directives to construct a canonical name for the
server. This name is used in all self-referential URLs, and for the
values of <CODE>SERVER_NAME</CODE> and <CODE>SERVER_PORT</CODE> in CGIs.
<P>With <CODE>UseCanonicalName off</CODE> Apache will form
self-referential URLs using the hostname and port supplied
by the client if any are supplied (otherwise it will use the
canonical name). These values are the same that are used to
implement <A HREF="/vhosts/name-based.html">name based virtual
hosts</A>, and are available with the same clients. The CGI variables
<CODE>SERVER_NAME</CODE> and <CODE>SERVER_PORT</CODE> will be constructed
from the client supplied values as well.
<P>An example where this may be useful is on an intranet server where
you have users connecting to the machine using short names such as
<CODE>www</CODE>. You'll notice that if the users type a shortname,
and a URL which is a directory, such as <CODE>http://www/splat</CODE>,
<EM>without the trailing slash</EM> then Apache will redirect them to
<CODE>http://www.domain.com/splat/</CODE>. If you have authentication
enabled, this will cause the user to have to reauthenticate twice (once
for <CODE>www</CODE> and once again for <CODE>www.domain.com</CODE>).
But if <CODE>UseCanonicalName</CODE> is set off, then Apache will redirect
to <CODE>http://www/splat/</CODE>.
<P>There is a third option, <CODE>UseCanonicalName DNS</CODE>, which
is intended for use with mass IP-based virtual hosting to support
ancient clients that do not provide a <CODE>Host:</CODE> header. With
this option Apache does a reverse DNS lookup on the server IP address
that the client connected to in order to work out self-referential URLs.
<P><STRONG>Warning:</STRONG> if CGIs make assumptions about the values of
<CODE>SERVER_NAME</CODE> they may be broken by this option. The client
is essentially free to give whatever value they want as a hostname.
But if the CGI is only using <CODE>SERVER_NAME</CODE> to construct
self-referential URLs then it should be just fine.
<P><STRONG>See also:</STRONG>
<A HREF="#servername">ServerName</A>,
<A HREF="#port">Port</A>
<P><HR>
<H2><A NAME="user">User directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt User} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> User <EM>unix-userid</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>User #-1</CODE><BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The User directive sets the userid as which the server will answer requests.
In order to use this directive, the standalone server must be run initially
as root. <EM>Unix-userid</EM> is one of:
<DL>
<DT>A username
<DD>Refers to the given user by name.
<DT># followed by a user number.
<DD>Refers to a user by their number.
</DL>
The user should have no privileges which result in it being able to access
files which are not intended to be visible to the outside world, and
similarly, the user should not be able to execute code which is not
meant for httpd requests. It is recommended that you set up a new user and
group specifically for running the server. Some admins use user
<CODE>nobody</CODE>, but this is not always possible or desirable.
For example mod_proxy's cache, when enabled, must be accessible to this user
(see the <A HREF="mod_proxy.html#cacheroot"><CODE>CacheRoot</CODE>
directive</A>).<P>
Notes: If you start the server as a non-root user, it will fail to change
to the lesser privileged user, and will instead continue to run as
that original user. If you do start the server as root, then it is normal
for the parent process to remain running as root.<P>
Special note: Use of this directive in &lt;VirtualHost&gt; requires a
properly configured <A HREF="/suexec.html">suEXEC wrapper</A>.
When used inside a &lt;VirtualHost&gt; in this manner, only the user
that CGIs are run as is affected. Non-CGI requests are still processed
with the user specified in the main User directive.<P>
SECURITY: Don't set User (or <A HREF="#group">Group</A>) to
<CODE>root</CODE> unless you know exactly what you are doing, and what the
dangers are.<P><HR>
<H2><A NAME="virtualhost">&lt;VirtualHost&gt; directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt VirtualHost} section directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;VirtualHost <EM>addr</EM>[:<EM>port</EM>]
...&gt; ...
&lt;/VirtualHost&gt; <BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> Core.<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Non-IP address-based Virtual Hosting only
available in Apache 1.1 and later.<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Multiple address support only available in
Apache 1.2 and later.<P>
&lt;VirtualHost&gt; and &lt;/VirtualHost&gt; are used to enclose a group of
directives which will apply only to a particular virtual host.
Any directive which is allowed in a virtual host context may be used.
When the server receives a request for a document on a particular virtual
host, it uses the configuration directives enclosed in the &lt;VirtualHost&gt;
section. <EM>Addr</EM> can be
<MENU>
<LI>The IP address of the virtual host
<LI>A fully qualified domain name for the IP address of the virtual host.
</MENU> Example:
<BLOCKQUOTE>
<CODE>
&lt;VirtualHost 10.1.2.3&gt; <BR>
ServerAdmin webmaster@host.foo.com <BR>
DocumentRoot /www/docs/host.foo.com <BR>
ServerName host.foo.com <BR>
ErrorLog logs/host.foo.com-error_log <BR>
TransferLog logs/host.foo.com-access_log <BR>
&lt;/VirtualHost&gt;
</CODE></BLOCKQUOTE>
Each VirtualHost must correspond to a different IP address, different port
number or a
different host name for the server, in the latter case the server
machine must be configured to accept IP packets for multiple
addresses. (If the machine does not have multiple network interfaces,
then this can be accomplished with the <CODE>ifconfig alias</CODE>
command (if your OS supports it), or with kernel patches like <A
HREF="/misc/vif-info.html">VIF</A> (for SunOS(TM) 4.1.x)).<P>
The special name <CODE>_default_</CODE> can be specified in which case
this virtual host will match any IP address that is not explicitly listed
in another virtual host. In the absence of any _default_ virtual host
the "main" server config, consisting of all those definitions outside
any VirtualHost section, is used when no match occurs.<P>
You can specify a <CODE>:port</CODE> to change the port that is matched.
If unspecified then it defaults to the same port as the most recent
<CODE><A HREF="#port">Port</A></CODE> statement of the main server. You
may also specify <CODE>:*</CODE> to match all ports on that address.
(This is recommended when used with <CODE>_default_</CODE>.)<P>
<STRONG>SECURITY</STRONG>: See the
<A HREF="/misc/security_tips.html">security tips</A>
document for details on why your security could be compromised if
the directory where logfiles are stored is writable by anyone other
than the user that starts the server.
<P><STRONG>NOTE</STRONG>: The use of &lt;VirtualHost&gt; does
<STRONG>not</STRONG> affect what addresses Apache listens on. You may
need to ensure that Apache is listening on the correct addresses using
either <A HREF="#bindaddress">BindAddress</A> or <A
HREF="#listen">Listen</A>.
<P><STRONG>See also:</STRONG>
<A HREF="/vhosts/index.html">Apache Virtual Host documentation</A><BR>
<STRONG>See also:</STRONG>
<A HREF="/dns-caveats.html">Warnings about DNS and Apache</A><BR>
<STRONG>See also:</STRONG>
<A HREF="/bind.html">Setting which addresses and ports Apache uses</A><BR>
<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
Location and Files sections work</A> for an explanation of how these
different sections are combined when a request is received
</P>
<!--#include virtual="footer.html" -->
</BODY>
</HTML>