core.html revision f3b8716c7802927370e9c53c4f9637410ce8f427
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User<HTML>
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User<HEAD>
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User<TITLE>Apache Core Features</TITLE>
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User</HEAD>
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User<BODY
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User BGCOLOR="#FFFFFF"
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User TEXT="#000000"
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User LINK="#0000FF"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User VLINK="#000080"
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User ALINK="#FF0000"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User>
f9ce6280cec79deb16ff6d9807aa493ff23e10d9Tinderbox User<!--#include virtual="header.html" -->
1ca759b3f5c0672b2a66bc02288fe010cabbfe37Tinderbox User
f9ce6280cec79deb16ff6d9807aa493ff23e10d9Tinderbox User<H1 ALIGN="CENTER">Apache Core Features</H1>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntThese configuration parameters control the core Apache features, and are
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Useralways available.
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User</P>
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User<H2>Directives</H2>
e285c11870c6263cd79b418e104c7eb3e2d96952Tinderbox User<UL>
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User<LI><A HREF="#accessconfig">AccessConfig</A>
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User<LI><A HREF="#accessfilename">AccessFileName</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#addmodule">AddModule</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#allowoverride">AllowOverride</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#authname">AuthName</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#authtype">AuthType</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#bindaddress">BindAddress</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#bs2000authfile">BS2000AuthFile</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#clearmodulelist">ClearModuleList</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#contentdigest">ContentDigest</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#coredumpdirectory">CoreDumpDirectory</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#defaulttype">DefaultType</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#directory">&lt;Directory&gt;</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#directorymatch">&lt;DirectoryMatch&gt;</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#documentroot">DocumentRoot</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#errordocument">ErrorDocument</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#errorlog">ErrorLog</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#files">&lt;Files&gt;</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#filesmatch">&lt;FilesMatch&gt;</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#group">Group</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#hostnamelookups">HostNameLookups</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#identitycheck">IdentityCheck</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#ifmodule">&lt;IfModule&gt;</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#include">Include</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#keepalive">KeepAlive</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#keepalivetimeout">KeepAliveTimeout</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#limit">&lt;Limit&gt;</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#listen">Listen</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#listenbacklog">ListenBacklog</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#location">&lt;Location&gt;</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#locationmatch">&lt;LocationMatch&gt;</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#lockfile">LockFile</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#loglevel">LogLevel</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#maxclients">MaxClients</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#maxkeepaliverequests">MaxKeepAliveRequests</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#maxrequestsperchild">MaxRequestsPerChild</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#maxspareservers">MaxSpareServers</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#minspareservers">MinSpareServers</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#namevirtualhost">NameVirtualHost</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#options">Options</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#pidfile">PidFile</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#port">Port</A>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<LI><A HREF="#require">require</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#resourceconfig">ResourceConfig</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#rlimitcpu">RLimitCPU</A>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<LI><A HREF="#rlimitmem">RLimitMEM</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI><A HREF="#rlimitnproc">RLimitNPROC</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#satisfy">Satisfy</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#scoreboardfile">ScoreBoardFile</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#sendbuffersize">SendBufferSize</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#serveradmin">ServerAdmin</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#serveralias">ServerAlias</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#servername">ServerName</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#serverpath">ServerPath</A>
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<LI><A HREF="#serverroot">ServerRoot</A>
e2f974003e61b59321a99f01a6f43576d9b76231Tinderbox User<LI><A HREF="#serversignature">ServerSignature</A>
e2f974003e61b59321a99f01a6f43576d9b76231Tinderbox User<LI><A HREF="#servertype">ServerType</A>
576bce9d7331498ca5453f8743f94ed8e2e59d9fTinderbox User<LI><A HREF="#startservers">StartServers</A>
576bce9d7331498ca5453f8743f94ed8e2e59d9fTinderbox User<LI><A HREF="#threadsperchild">ThreadsPerChild</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#timeout">TimeOut</A>
63d4f7ac5634f3b20d42cc160c01ac03d013b11cTinderbox User<LI><A HREF="#usecanonicalname">UseCanonicalName</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#user">User</A>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI><A HREF="#virtualhost">&lt;VirtualHost&gt;</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</UL>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<HR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<H2><A name="accessconfig">AccessConfig directive</A></H2>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<!--%plaintext &lt;?INDEX {\tt AccessConfig} directive&gt; -->
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User HREF="directive-dict.html#Syntax"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Syntax:</STRONG></A> AccessConfig <EM>filename</EM><BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A
1ffe3f29e3cd0d8355500e9fd34de918ad9b4a01Tinderbox User HREF="directive-dict.html#Default"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Default:</STRONG></A> <CODE>AccessConfig conf/access.conf</CODE><BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User HREF="directive-dict.html#Context"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Context:</STRONG></A> server config, virtual host<BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User HREF="directive-dict.html#Status"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Status:</STRONG></A> core<P>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserThe server will read this file for more directives after reading the
1ffe3f29e3cd0d8355500e9fd34de918ad9b4a01Tinderbox User<A HREF="#resourceconfig">ResourceConfig</A> file. <EM>Filename</EM> is
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox Userrelative to the <A HREF="#serverroot">ServerRoot</A>.
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox UserThis feature can be disabled using:
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<BLOCKQUOTE><CODE>AccessConfig /dev/null</CODE></BLOCKQUOTE>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserHistorically, this file only contained
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A HREF="#directory">&lt;Directory&gt;</A> sections; in fact it can now
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox Usercontain any server directive allowed in the <EM>server config</EM> context.
1ffe3f29e3cd0d8355500e9fd34de918ad9b4a01Tinderbox User<P><HR>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<H2><A name="accessfilename">AccessFileName directive</A></H2>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<!--%plaintext &lt;?INDEX {\tt AccessFileName} directive&gt; -->
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<A
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User HREF="directive-dict.html#Syntax"
3ba1f79ade054aa6a0dc5032502bcdcf357cd7bdTinderbox User REL="Help"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User><STRONG>Syntax:</STRONG></A> AccessFileName <EM>filename filename ...</EM><BR>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<A
3ba1f79ade054aa6a0dc5032502bcdcf357cd7bdTinderbox User HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Default:</STRONG></A> <CODE>AccessFileName .htaccess</CODE><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config, virtual host<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Compatibility"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Compatibility:</STRONG></A> AccessFileName can accept more than one filename only in Apache 1.3 and later<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserWhen returning a document to the client the server looks for the first existing
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntaccess control file from this list of names in every directory of the path to
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntthe document, if access control files are enabled for that directory.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntFor example:
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<BLOCKQUOTE><CODE>AccessFileName .acl</CODE></BLOCKQUOTE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntbefore returning the document /usr/local/web/index.html, the
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userserver will read /.acl, /usr/.acl, /usr/local/.acl and /usr/local/web/.acl
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntfor directives, unless they have been disabled with
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<BLOCKQUOTE><CODE>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User&lt;Directory /&gt;<BR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox UserAllowOverride None<BR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User&lt;/Directory&gt;</CODE></BLOCKQUOTE><P><HR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<H2><A name="addmodule">AddModule directive</A></H2>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<!--%plaintext &lt;?INDEX {\tt AddModule} directive&gt; -->
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<A
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User HREF="directive-dict.html#Syntax"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> AddModule <EM>module module ...</EM><BR>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Context:</STRONG></A> server config <BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Compatibility"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Compatibility:</STRONG></A> AddModule is only available in Apache 1.2 and later<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserThe server can have modules compiled in which are not actively in use.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntThis directive can be used to enable the use of those modules. The
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntserver comes with a pre-loaded list of active modules; this list can
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntbe cleared with the <A HREF="#clearmodulelist">ClearModuleList</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirective.<P><HR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="allowoverride">AllowOverride directive</A></H2>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<!--%plaintext &lt;?INDEX {\tt AllowOverride} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Syntax"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Syntax:</STRONG></A> AllowOverride <EM>override override ...</EM><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Default:</STRONG></A> <CODE>AllowOverride All</CODE><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Context:</STRONG></A> directory<BR>
9d557856c2a19ec95ee73245f60a92f8675cf5baTinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserWhen the server finds an .htaccess file (as specified by
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="#accessfilename">AccessFileName</A>) it needs to know which
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirectives declared in that file can override earlier access information.<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<EM>Override</EM> can be set to <CODE>None</CODE>, in which case the server
76cf91b5df7a1bc450afcb9ce7585c61bb87de68Tinderbox Userwill not read the file, <CODE>All</CODE> in which case the server will
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox Userallow all the directives, or one or more of the following:
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<DL>
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<DT>AuthConfig
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<DD>
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<!--%plaintext &lt;?INDEX {\tt AuthConfig} override&gt; -->
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox UserAllow use of the authorization directives
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User(<A HREF="mod_auth_dbm.html#authdbmgroupfile">AuthDBMGroupFile</A>,
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<A HREF="mod_auth_dbm.html#authdbmuserfile">AuthDBMUserFile</A>,
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A>,
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<A HREF="#authname">AuthName</A>, <A HREF="#authtype">AuthType</A>,
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<A HREF="mod_auth.html#authuserfile">AuthUserFile</A>,
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<A HREF="#require">require</A>, etc.).
1700442a7751c2bbdafe2d039cebbd8316496957Tinderbox User<DT>FileInfo
76cf91b5df7a1bc450afcb9ce7585c61bb87de68Tinderbox User<DD>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<!--%plaintext &lt;?INDEX {\tt FileInfo} override&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntAllow use of the directives controlling document types
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User(<A HREF="mod_mime.html#addencoding">AddEncoding</A>,
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_mime.html#addlanguage">AddLanguage</A>,
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="mod_mime.html#addtype">AddType</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="#defaulttype">DefaultType</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="#errordocument">ErrorDocument</A>,
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_negotiation.html#languagepriority">LanguagePriority</A>, etc.).
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<DT>Indexes
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<DD>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt Indexes} override&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntAllow use of the directives controlling directory indexing
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt(<A HREF="mod_autoindex.html#adddescription">AddDescription</A>,
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_autoindex.html#addicon">AddIcon</A>,
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="mod_autoindex.html#addiconbyencoding">AddIconByEncoding</A>,
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_autoindex.html#addiconbytype">AddIconByType</A>,
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="mod_autoindex.html#defaulticon">DefaultIcon</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_dir.html#directoryindex">DirectoryIndex</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_autoindex.html#fancyindexing">FancyIndexing</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_autoindex.html#headername">HeaderName</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_autoindex.html#indexignore">IndexIgnore</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_autoindex.html#indexoptions">IndexOptions</A>,
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A HREF="mod_autoindex.html#readmename">ReadmeName</A>, etc.).
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<DT>Limit
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<DD>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<!--%plaintext &lt;?INDEX {\tt Limit} override&gt; -->
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox UserAllow use of the directives controlling host access (allow, deny and order).
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<DT>Options
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<DD>
d3e2a34ffb68b51dbe4da73420b9f88e847ff4a6Tinderbox User<!--%plaintext &lt;?INDEX {\tt Options} override&gt; -->
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox UserAllow use of the directives controlling specific directory features
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User(<A HREF="#options">Options</A> and
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<A HREF="mod_include.html#xbithack">XBitHack</A>).
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User</DL><P><HR>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<H2><A name="authname">AuthName directive</A></H2>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<!--%plaintext &lt;?INDEX {\tt AuthName} directive&gt; -->
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<A
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User HREF="directive-dict.html#Syntax"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User REL="Help"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User><STRONG>Syntax:</STRONG></A> AuthName <EM>auth-domain</EM><BR>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<A
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User HREF="directive-dict.html#Context"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User REL="Help"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User<A
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User HREF="directive-dict.html#Override"
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User REL="Help"
a1ff871f78b7d907d6fc3a382beea2a640fe8423Tinderbox User><STRONG>Override:</STRONG></A> AuthConfig<BR>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User<A
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User HREF="directive-dict.html#Status"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User REL="Help"
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User><STRONG>Status:</STRONG></A> core<P>
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox User
3241ddcf9354c5ab50f4df5a656e72a5c68e172bTinderbox UserThis directive sets the name of the authorization realm for a directory.
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserThis realm is given to the client so that the user knows which username and
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntpassword to send.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntIt must be accompanied by <A HREF="#authtype">AuthType</A> and
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="#require">require</A> directives, and directives such as
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="authtype">AuthType directive</A></H2>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<!--%plaintext &lt;?INDEX {\tt AuthType} directive&gt; -->
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Syntax"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> AuthType <EM>type</EM><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User REL="Help"
e2b184f84e846bbcb764b6f0aef5dcd583d3d7a1Tinderbox User><STRONG>Context:</STRONG></A> directory, .htaccess<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Override"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Override:</STRONG></A> AuthConfig<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntThis directive selects the type of user authentication for a directory.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntOnly <CODE>Basic</CODE> is currently implemented.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt Basic} authentication scheme&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntIt must be accompanied by <A HREF="#authname">AuthName</A> and
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="#require">require</A> directives, and directives such as
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="mod_auth.html#authuserfile">AuthUserFile</A> and
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="mod_auth.html#authgroupfile">AuthGroupFile</A> to work.<P><HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="bindaddress">BindAddress directive</A></H2>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt BindAddress} directive&gt; -->
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Syntax"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Syntax:</STRONG></A> BindAddress <EM>saddr</EM><BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Default:</STRONG></A> <CODE>BindAddress *</CODE><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Context"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Status:</STRONG></A> core<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntA Unix&#174; http server can either listen for connections to every
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntIP address of the server machine, or just one IP address of the server
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Usermachine. <EM>Saddr</EM> can be
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<MENU>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI>*
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI>An IP address
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI>A fully-qualified Internet domain name
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</MENU>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntIf the value is *, then the server will listen for connections on
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userevery IP address, otherwise it will only listen on the IP address
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userspecified. <P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntOnly one <CODE>BindAddress</CODE> directive can be used. For more
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Usercontrol over which address and ports Apache listens to, use the
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<CODE><A HREF="#listen">Listen</A></CODE> directive instead of
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>BindAddress</CODE>.<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>BindAddress</CODE> can be used as an alternative method for
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Usersupporting <A HREF="/vhosts/index.html">virtual hosts</A> using
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Usermultiple independent servers, instead of using <CODE><A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntHREF="#virtualhost">&lt;VirtualHost&gt;</A></CODE> sections.
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<P><STRONG>See Also:</STRONG>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A HREF="/dns-caveats.html">DNS Issues</A><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<STRONG>See Also:</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="/bind.html">Setting which addresses and ports Apache uses</A></P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<HR>
0226754d9e537fd56b690d5890cfe215a6c59f89Tinderbox User
0226754d9e537fd56b690d5890cfe215a6c59f89Tinderbox User<H2><A name="bs2000authfile">BS2000AuthFile directive</A></H2>
0226754d9e537fd56b690d5890cfe215a6c59f89Tinderbox User<!--%plaintext &lt;?INDEX {\tt BS2000AuthFile} directive&gt; -->
0226754d9e537fd56b690d5890cfe215a6c59f89Tinderbox User<A
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User HREF="directive-dict.html#Syntax"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User REL="Help"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User><STRONG>Syntax:</STRONG></A> BS2000AuthFile <EM>authfile</EM><BR>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Default:</STRONG></A> <EM>none</EM><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Context"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Status"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<BR>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<STRONG>Compatibility:</STRONG></A> BS2000AuthFile is only available for BS2000 machines, as of Apache 1.3 and later.<P>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserThe <CODE>BS2000AuthFile</CODE> directive is available for BS2000 hosts
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Useronly. It must be used to define the password file which is used to
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntchange the BS2000 task environment of the server to the non-privileged
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntaccount specified by the <A HREF="#user">User</A> directive. This is
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntrequired in the BS2000 POSIX subsystem (by performing a sub-LOGON) to
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntprevent CGI scripts from accessing resources of the privileged account
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntwhich started the server, usually <SAMP>TSOS</SAMP>.<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntNote that the specified <EM>authfile</EM> must be owned by the super
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntuser and must not be readable or writable by anyone else, otherwise
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserApache will refuse to start and exit with an error message.<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserOnly one <CODE>BS2000AuthFile</CODE> directive can be used. <P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P><STRONG>See Also:</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="/ebcdic.html">Apache EBCDIC port</A></P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<HR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<H2><A name="clearmodulelist">ClearModuleList directive</A></H2>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt ClearModuleList} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Syntax"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> ClearModuleList<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Context"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> core<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Compatibility"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Compatibility:</STRONG></A> ClearModuleList is only available in Apache 1.2 and later<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntThe server comes with a built-in list of active modules. This
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userdirective clears the list. It is assumed that the list will then be
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userre-populated using the <A HREF="#addmodule">AddModule</A> directive.<P><HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="contentdigest">ContentDigest directive</A></H2>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt ContentDigest} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Syntax"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> ContentDigest <EM>on|off</EM><BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Default:</STRONG></A> <CODE>ContentDigest off</CODE><BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config, virtual host, directory, .htaccess<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Override"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User REL="Help"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User><STRONG>Override:</STRONG></A> AuthConfig<BR>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<A
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User HREF="directive-dict.html#Status"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User REL="Help"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User><STRONG>Status:</STRONG></A> experimental<P>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<A
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User HREF="directive-dict.html#Compatibility"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User REL="Help"
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User><STRONG>Compatibility:</STRONG></A> ContentDigest is only available in Apache 1.1 and later<P>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox UserThis directive enables the generation of <CODE>Content-MD5</CODE> headers
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Useras defined in RFC1864 respectively RFC2068.<P>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox UserMD5 is an algorithm for computing a "message digest" (sometimes called
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User"fingerprint") of arbitrary-length data, with a high degree of confidence
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Userthat any alterations in the data will be reflected in alterations in the
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Usermessage digest.<P>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox UserThe <CODE>Content-MD5</CODE> header provides an end-to-end message
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Userintegrity check (MIC) of the entity-body. A proxy or client may check this
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Userheader for detecting accidental modification of the entity-body
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox Userin transit.
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox UserExample header:
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User<PRE> Content-MD5: AuLb7Dp1rqtRtxz2m9kRpA==</PRE><P>
eb2a5f51bd5c100799d93d51c9e22666cbd64d90Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserNote that this can cause performance problems on your server
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntsince the message digest is computed on every request
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt(the values are not cached).<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>Content-MD5</CODE> is only sent for documents served by the
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntcore, and not by any module. For example, SSI documents, output from
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCGI scripts, and byte range responses do not have this header.
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="coredumpdirectory">CoreDumpDirectory directive</A></H2>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt CoreDumpDirectory} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Syntax"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> CoreDumpDirectory <EM>directory</EM><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Default:</STRONG></A> the same location as ServerRoot<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Status:</STRONG></A> core<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox UserThis controls the directory to which Apache attempts to switch before
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdumping core. The default is in the <A HREF="#serverroot">ServerRoot</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirectory, however since this should not be writable by the user
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntthe server runs as, core dumps won't normally get written. If you
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userwant a core dump for debugging, you can use this directive to place
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userit in a different location.<P><HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="defaulttype">DefaultType directive</A></H2>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<!--%plaintext &lt;?INDEX {\tt DefaultType} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Syntax"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Syntax:</STRONG></A> DefaultType <EM>mime-type</EM><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Default"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Default:</STRONG></A> <CODE>DefaultType text/html</CODE><BR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config, virtual host, directory, .htaccess<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Override"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Override:</STRONG></A> FileInfo<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox User HREF="directive-dict.html#Status"
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox User REL="Help"
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox User><STRONG>Status:</STRONG></A> core<P>
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox User
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox UserThere will be times when the server is asked to provide a document
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox Userwhose type cannot be determined by its MIME types mappings.<P>
e62b9c9ce6413fb183c8116381e75dcd07ca5517Tinderbox User
d7a61cfbe56ebfa1682e949e48b4d08840234d8fTinderbox UserThe server must inform the client of the content-type of the document, so in
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox Userthe event of an unknown type it uses the <CODE>DefaultType</CODE>. For
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox Userexample:
d7a61cfbe56ebfa1682e949e48b4d08840234d8fTinderbox User<BLOCKQUOTE><CODE>DefaultType image/gif</CODE></BLOCKQUOTE>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox Userwould be appropriate for a directory which contained many gif images
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox Userwith filenames missing the .gif extension.<P><HR>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<H2><A name="directory">&lt;Directory&gt; directive</A></H2>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<!--%plaintext &lt;?INDEX {\tt Directory} section directive&gt; -->
d7a61cfbe56ebfa1682e949e48b4d08840234d8fTinderbox User<A
832fa787d4a13fa89d64f868e51016ff4adb0d89Tinderbox User HREF="directive-dict.html#Syntax"
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User REL="Help"
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User><STRONG>Syntax:</STRONG></A> &lt;Directory <EM>directory</EM>&gt; ... &lt;/Directory&gt; <BR>
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<A
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User HREF="directive-dict.html#Context"
832fa787d4a13fa89d64f868e51016ff4adb0d89Tinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Context:</STRONG></A> server config, virtual host<BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<A
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User HREF="directive-dict.html#Status"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User REL="Help"
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User><STRONG>Status:</STRONG></A> Core. <P>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User&lt;Directory&gt; and &lt;/Directory&gt; are used to enclose a group of
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox Userdirectives which will apply only to the named directory and sub-directories
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Userof that directory. Any directive which is allowed in a directory
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Usercontext may be used. <EM>Directory</EM> is either the full path to a directory,
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Useror a wild-card string. In a wild-card string, `?' matches any single character,
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Userand `*' matches any sequences of characters. As of Apache 1.3, you
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Usermay also use `[]' character ranges like in the shell. Also as of Apache 1.3
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Usernone of the wildcards match a `/' character, which more closely mimics the
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox Userbehaviour of Unix shells.
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox UserExample:
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox User<PRE>
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox User &lt;Directory /usr/local/httpd/htdocs&gt;
a548226d23f595f52e43d1818a05ab3106ffb340Tinderbox User Options Indexes FollowSymLinks
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt &lt;/Directory&gt;
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User</PRE>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P><STRONG>Apache 1.2 and above:</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntExtended regular expressions can also be used, with the addition of the
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<CODE>~</CODE> character. For example:</P>
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User<PRE>
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User &lt;Directory ~ &quot;^/www/.*/[0-9]{3}&quot;&gt;
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User</PRE>
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox Userwould match directories in /www/ that consisted of three numbers.
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User
006283c42350464bc285c4481bce0a3b5a3dd8d0Tinderbox User<P>If multiple (non-regular expression) directory sections match the
006283c42350464bc285c4481bce0a3b5a3dd8d0Tinderbox Userdirectory (or its parents) containing
006283c42350464bc285c4481bce0a3b5a3dd8d0Tinderbox Usera document, then the directives are applied in the order of shortest match
006283c42350464bc285c4481bce0a3b5a3dd8d0Tinderbox Userfirst, interspersed with the directives from the
006283c42350464bc285c4481bce0a3b5a3dd8d0Tinderbox User<A HREF="#accessfilename">.htaccess</A> files. For example, with
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User<BLOCKQUOTE><CODE>
3cdd0f1bc921f19e790b4f795b90eabc94e9a74aTinderbox User&lt;Directory /&gt;<BR>
6758b59e57af88bdf466e63c0856043df44f8dd0Tinderbox UserAllowOverride None<BR>
6758b59e57af88bdf466e63c0856043df44f8dd0Tinderbox User&lt;/Directory&gt;<BR><BR>
6758b59e57af88bdf466e63c0856043df44f8dd0Tinderbox User&lt;Directory /home/*&gt;<BR>
6758b59e57af88bdf466e63c0856043df44f8dd0Tinderbox UserAllowOverride FileInfo<BR>
6758b59e57af88bdf466e63c0856043df44f8dd0Tinderbox User&lt;/Directory&gt;</CODE></BLOCKQUOTE>
dec590a3deb8e87380a8bd3a77d535dba3729bf6Tinderbox Userfor access to the document <CODE>/home/web/dir/doc.html</CODE> the
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox Usersteps are:
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<MENU>
dec590a3deb8e87380a8bd3a77d535dba3729bf6Tinderbox User<LI>Apply directive <CODE>AllowOverride None</CODE> (disabling
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<CODE>.htaccess</CODE> files).
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI>Apply directive <CODE>AllowOverride FileInfo</CODE> (for directory
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>/home/web</CODE>).
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI>Apply any FileInfo directives in <CODE>/home/web/.htaccess</CODE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</MENU>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserRegular expression directory sections are handled slightly differently
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userby Apache 1.2 and 1.3. In Apache 1.2 they are interspersed with the normal
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirectory sections and applied in the order they appear in the configuration
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntfile. They are applied only once, and apply when the shortest match
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntpossible occurs. In Apache 1.3 regular expressions are not considered
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Useruntil after all of the normal sections have been applied. Then all of
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userthe regular expressions are tested in the order they appeared in the
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntconfiguration file. For example, with
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<BLOCKQUOTE><CODE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt&lt;Directory ~ abc$&gt;<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt... directives here ...<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt&lt;/Directory&gt;<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</CODE></BLOCKQUOTE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntSuppose that the filename being accessed is
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>/home/abc/public_html/abc/index.html</CODE>. The server
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntconsiders each of <CODE>/</CODE>, <CODE>/home</CODE>, <CODE>/home/abc</CODE>,
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<CODE>/home/abc/public_html</CODE>, and <CODE>/home/abc/public_html/abc</CODE>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userin that order. In Apache 1.2, when
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<CODE>/home/abc</CODE> is considered, the regular expression will match
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntand be applied. In Apache 1.3 the regular expression isn't considered
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userat all at that point in the tree. It won't be considered until after
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userall normal &lt;Directory&gt;s and <CODE>.htaccess</CODE> files have
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntbeen applied. Then the regular expression will
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntmatch on <CODE>/home/abc/public_html/abc</CODE> and be applied.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntNote that the default Apache access for &lt;Directory /&gt; is
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<SAMP>Allow from All</SAMP>. This means that Apache will serve any file
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Usermapped from an URL. It is recommended that you change this with a block
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntsuch as
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<PRE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt &lt;Directory /&gt;
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt Order Deny,Allow
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt Deny from All
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt &lt;/Directory&gt;
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</PRE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntand then override this for directories you <EM>want</EM> accessible.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntSee the
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="/misc/security_tips.html"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt>Security Tips</A>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntpage for more details.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserThe directory sections typically occur in the access.conf file, but they
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntmay appear in any configuration file. &lt;Directory&gt; directives cannot
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntnest, and cannot appear in a <A HREF="#limit">&lt;Limit&gt;</A> section.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntLocation and Files sections work</A> for an explanation of how these
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdifferent sections are combined when a request is received
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<H2><A name="directorymatch">&lt;DirectoryMatch&gt;</A></H2>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
e285c11870c6263cd79b418e104c7eb3e2d96952Tinderbox User HREF="directive-dict.html#Syntax"
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User REL="Help"
46472a450e043434d78fa18edc73bca8c47f3981Tinderbox User><STRONG>Syntax:</STRONG></A> &lt;DirectoryMatch <EM>regex</EM>&gt; ... &lt;/DirectoryMatch&gt; <BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Context:</STRONG></A> server config, virtual host<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Status:</STRONG></A> Core.<BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Compatibility"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Compatibility:</STRONG></A> Available in Apache 1.3 and later
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P>&lt;DirectoryMatch&gt; and &lt;/DirectoryMatch&gt; are used to enclose a group of
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirectives which will apply only to the named directory and sub-directories
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntof that directory, the same as <A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntHREF="#directory">&lt;Directory&gt;</A>. However, it takes as an
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntargument a regular expression. For example:</P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<PRE>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt &lt;DirectoryMatch &quot;^/www/.*/[0-9]{3}&quot;&gt;
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</PRE>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<P>would match directories in /www/ that consisted of three numbers.</P>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<P><STRONG>See Also:</STRONG>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A HREF="#directory">&lt;Directory&gt;</A> for a description of how
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntregular expressions are mixed in with normal &lt;Directory&gt;s.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<STRONG>See also</STRONG>: <A HREF="/sections.html">How Directory,
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserLocation and Files sections work</A> for an explanation of how these
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdifferent sections are combined when a request is received
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<HR>
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<H2><A NAME="documentroot">DocumentRoot directive</A></H2>
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<!--%plaintext &lt;?INDEX {\tt DocumentRoot} directive&gt; -->
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<A
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User HREF="directive-dict.html#Syntax"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User REL="Help"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User><STRONG>Syntax:</STRONG></A> DocumentRoot <EM>directory-filename</EM><BR>
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<A
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User HREF="directive-dict.html#Default"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User REL="Help"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User><STRONG>Default:</STRONG></A> <CODE>DocumentRoot
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User/usr/local/apache/htdocs</CODE><BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Context"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt><STRONG>Context:</STRONG></A> server config, virtual host<BR>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<A
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User HREF="directive-dict.html#Status"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User><STRONG>Status:</STRONG></A> core<P>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserThis directive sets the directory from which httpd will serve files.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntUnless matched by a directive like Alias, the server appends the path
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntfrom the requested URL to the document root to make the path to the
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdocument. Example:
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<BLOCKQUOTE><CODE>DocumentRoot /usr/web</CODE></BLOCKQUOTE>
a179cbdf652095d00e7774320592f25eab0210d8Tinderbox Userthen an access to <CODE>http://www.my.host.com/index.html</CODE> refers
a179cbdf652095d00e7774320592f25eab0210d8Tinderbox Userto <CODE>/usr/web/index.html</CODE>.
a179cbdf652095d00e7774320592f25eab0210d8Tinderbox User
a179cbdf652095d00e7774320592f25eab0210d8Tinderbox User<P>There appears to be a bug in mod_dir which causes problems when the
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox UserDocumentRoot has a trailing slash (i.e. "DocumentRoot /usr/web/") so
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox Userplease avoid that.
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User
6b7cba2b10d6cb5363d94b434b0d22ecfb33a6f3Tinderbox User<P><HR>
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<H2><A name="errordocument">ErrorDocument directive</A></H2>
8a48b6b9b6fa8486f24b22d1972b2b6ebb36a4a4Tinderbox User<!--%plaintext &lt;?INDEX {\tt ErrorDocument} directive&gt; -->
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User<A
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User HREF="directive-dict.html#Syntax"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User REL="Help"
f33abec8a62ab6f2b867d7189dfffa72592c027bTinderbox User><STRONG>Syntax:</STRONG></A> ErrorDocument <EM>error-code document</EM><BR>
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User<A
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User HREF="directive-dict.html#Context"
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User REL="Help"
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User><STRONG>Context:</STRONG></A> server config, virtual host, directory, .htaccess<BR>
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User<A
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User HREF="directive-dict.html#Status"
0cfa9af7edf7c3e13917f784557390e4b6612ee6Tinderbox User REL="Help"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User><STRONG>Status:</STRONG></A> core<BR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<A
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User HREF="directive-dict.html#Override"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User REL="Help"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User><STRONG>Override:</STRONG></A> FileInfo<BR>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<A
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User HREF="directive-dict.html#Compatibility"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User REL="Help"
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User><STRONG>Compatibility:</STRONG></A> The directory and .htaccess contexts
7e71f05d8643aca84914437c900cb716444507e4Tinderbox Userare only available in Apache 1.1 and later.<P>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User
7e71f05d8643aca84914437c900cb716444507e4Tinderbox UserIn the event of a problem or error, Apache can be configured to do
7e71f05d8643aca84914437c900cb716444507e4Tinderbox Userone of four things,
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<OL>
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<LI>output a simple hardcoded error message
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<LI>output a customized message
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI>redirect to a local URL to handle the problem/error
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<LI>redirect to an external URL to handle the problem/error
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt</OL>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox User<P>The first option is the default, while options 2-4 are configured
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox Userusing the <CODE>ErrorDocument</CODE> directive, which is followed by
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox Userthe HTTP response code and a message or URL.
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<P><EM>Messages</EM> in this context begin with a single quote
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User(<CODE>"</CODE>), which does not form part of the message itself.
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox UserApache will sometimes offer additional information regarding the
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox Userproblem/error.
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox User
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox User<P>URLs can begin with a slash (/) for local URLs, or be a full
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox UserURL which the client can resolve. Examples:
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox User<BLOCKQUOTE><CODE>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserErrorDocument 500 http://foo.example.com/cgi-bin/tester<BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserErrorDocument 404 /cgi-bin/bad_urls.pl<BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserErrorDocument 401 /subscription_info.html<BR>
260e8e04b0dc24cb884c789b5d9eb046457f264eTinderbox UserErrorDocument 403 "Sorry can't allow you access today
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox User</CODE></BLOCKQUOTE>
221870ba7bf08daf55db5a69a4de4bbdc4f2a93cTinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<P>Note that when you specify an <CODE>ErrorDocument</CODE> that
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userpoints to a remote URL (ie. anything with a method such as "http" in
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntfront of it) Apache will send a redirect to the client to tell it
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntwhere to find the document, even if the document ends up being
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Useron the same server.. This has several implications, the
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntmost important being that <STRONG>if you use an "ErrorDocument 401"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Huntdirective then it must refer to a local document.</STRONG> This results
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userfrom the nature of the HTTP basic authentication scheme.
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<P>See Also: <A HREF="/custom-error.html">documentation of customizable
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox Userresponses.</A><P><HR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<H2><A name="errorlog">ErrorLog directive</A></H2>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<!--%plaintext &lt;?INDEX {\tt ErrorLog} directive&gt; -->
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Syntax"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt REL="Help"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User><STRONG>Syntax:</STRONG></A> ErrorLog <EM>filename</EM>|<CODE>syslog</CODE><BR>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<A
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt HREF="directive-dict.html#Default"
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User REL="Help"
1c57c3f79db0bf0358bbe6d7b5ad650c0c852f4bTinderbox User><STRONG>Default:</STRONG></A> <CODE>ErrorLog logs/error_log</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 error log directive sets the name of the file to which the server will log
any errors it encounters. If the filename does not begin with a slash (/)
then it is assumed to be relative to the <A HREF="#serverroot">ServerRoot</A>.
If the filename begins with a pipe (|) then it is assumed to be a command to
spawn to handle the error log.
<P><STRONG>Apache 1.3 and above:</STRONG>
Using <CODE>syslog</CODE> instead of a filename enables logging via syslogd(8)
if the system supports it.
<P>
SECURITY: See the <A HREF="/misc/security_tips.html#serverroot">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>See also:</STRONG> <A HREF="#loglevel">LogLevel</A>
<P><HR>
<H2><A name="files">&lt;Files&gt; directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;Files <EM>filename</EM>&gt;
... &lt;/Files&gt;<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host, .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> only available in Apache
1.2 and above.<P>
<P>The &lt;Files&gt; directive provides for access control by
filename. It is comparable to the <A
HREF="#directory">&lt;Directory&gt;</A> directive and
<A HREF="#location">&lt;Location&gt;</A> directives. It
should be matched with a &lt;/Files&gt; directive. The
directives given within this section will be applied to any
object with a basename (last component of filename) matching
the specified filename.
<CODE>&lt;Files&gt;</CODE> sections are processed in the
order they appear in the configuration file, after the
&lt;Directory&gt; sections and <CODE>.htaccess</CODE> files are
read, but before &lt;Location&gt; sections. Note that
&lt;Files&gt; can be nested inside &lt;Directory&gt;
sections to restrict the portion of the filesystem they
apply to.</P>
<P>The <EM>filename</EM> argument should include a filename, or a
wild-card string, where `?' matches any single character, and `*' matches any
sequences of characters. Extended regular expressions can also be used,
with the addition of
the <CODE>~</CODE> character. For example:</P>
<PRE>
&lt;Files ~ &quot;\.(gif|jpe?g|png)$&quot;&gt;
</PRE>
would match most common Internet graphics formats. In Apache 1.3 and
later, <A HREF="#filesmatch">&lt;FilesMatch&gt;</A> is preferred,
however.
<P>Note that unlike <A
HREF="#directory"><CODE>&lt;Directory&gt;</CODE></A> and <A
HREF="#location"><CODE>&lt;Location&gt;</CODE></A> sections,
<CODE>&lt;Files&gt;</CODE> sections can be used inside .htaccess
files. This allows users to control access to their own files, at a
file-by-file level.
<P>
<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
<HR>
<H2><A name="filesmatch">&lt;FilesMatch&gt;</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;FilesMatch <EM>regex</EM>&gt;
... &lt;/Files&gt;<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> server config, virtual host, .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> only available in Apache
1.3 and above.<P>
<P>The &lt;FilesMatch&gt; directive provides for access control by
filename, just as the <A HREF="#files">&lt;Files&gt;</A> directive
does. However, it accepts a regular expression. For example:</P>
<PRE>
&lt;FilesMatch &quot;\.(gif|jpe?g|png)$&quot;&gt;
</PRE>
<P>would match most common Internet graphics formats.</P>
<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
<HR>
<H2><A name="group">Group directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt Group} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> Group <EM>unix-group</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>Group #-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 Group directive sets the group under which the server will answer requests.
In order to use this directive, the stand-alone server must be run initially
as root. <EM>Unix-group</EM> is one of:
<DL>
<DT>A group name
<DD>Refers to the given group by name.
<DT># followed by a group number.
<DD>Refers to a group by its number.
</DL>
It is recommended that you set up a new group specifically for running the
server. Some admins use user <CODE>nobody</CODE>, but this is not always
possible or desirable.<P>
Note: if you start the server as a non-root user, it will fail to change
to the specified group, and will instead continue to run as the group of the
original user. <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 group
that CGIs are run as is affected. Non-CGI requests are still processed
as the group specified in the main Group directive.<P>
SECURITY: See <A HREF="#user">User</A> for a discussion of the security
considerations.<P><HR>
<H2><A name="hostnamelookups">HostNameLookups directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt HostNameLookups} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> HostNameLookups <EM>on | off | double</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>HostNameLookups 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> <CODE>double</CODE> available only in Apache
1.3 and above.<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Default was <CODE>on</CODE> prior to Apache
1.3.<P>
This directive enables DNS lookups so that host names can be logged (and
passed to CGIs/SSIs in <CODE>REMOTE_HOST</CODE>).
The value <CODE>double</CODE> refers to doing double-reverse DNS.
That is, after a reverse lookup is performed, a forward lookup is then
performed on that result. At least one of the ip addresses in the forward
lookup must match the original address. (In "tcpwrappers" terminology
this is called <CODE>PARANOID</CODE>.)<P>
Regardless of the setting, when <A HREF="mod_access.html">mod_access</A>
is used for controlling access by hostname, a double reverse lookup
will be performed. This is necessary for security. Note that the
result of this double-reverse isn't generally available unless
you set <CODE>HostnameLookups double</CODE>. For example, if only
<CODE>HostnameLookups on</CODE> and a request is made to an object that
is protected by hostname restrictions, regardless of whether the
double-reverse fails or not, CGIs will still be passed the single-reverse
result in <CODE>REMOTE_HOST</CODE>.<P>
The default for this directive was previously <CODE>on</CODE> in
versions of Apache prior to 1.3. It was changed to <CODE>off</CODE>
in order to save the network traffic for those sites that don't truly
need the reverse lookups done. It is also better for the end users
because they don't have to suffer the extra latency that a lookup
entails.
Heavily loaded sites should leave this directive <CODE>off</CODE>, since DNS
lookups can take considerable amounts of time. The utility <EM>logresolve</EM>,
provided in the <EM>/support</EM> directory, can be used to look up host names
from logged IP addresses offline.<P><HR>
<H2><A name="identitycheck">IdentityCheck directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt IdentityCheck} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> IdentityCheck <EM>boolean</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>IdentityCheck 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<P>
This directive enables RFC1413-compliant logging of the remote user name
for each connection, where the client machine runs identd or something similar.
This information is logged in the access log. <EM>Boolean</EM> is either
<CODE>on</CODE> or <CODE>off</CODE>.<P>
The information should not be trusted in any way except for rudimentary usage
tracking.<P>
Note that this can cause serious latency problems accessing your server
since every request requires one of these lookups to be performed. When
firewalls are involved each lookup might possibly fail and add 30 seconds
of latency to each hit. So in general this is not very useful on public
servers accessible from the Internet.
<P><HR>
<H2><A NAME="ifmodule">&lt;IfModule&gt; directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;IfModule [!]<EM>module-name</EM>&gt; <EM>...</EM>
&lt;/IfModule&gt;<BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> None<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> all<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> IfModule is only available in 1.2 and
later.<P>
<P>
The &lt;IfModule <EM>test</EM>&gt;...&lt;/IfModule&gt;
section is used to mark directives that are conditional. The
directives within an IfModule section are only
processed if the <EM>test</EM> is true. If <EM>test</EM>
is false, everything between the start and end markers
is ignored.<P>
The <EM>test</EM> in the &lt;IfModule&gt; section directive
can be one of two forms:
<UL>
<LI><EM>module name</EM>
<LI>!<EM>module name</EM>
</UL>
<P>In the former case, the directives between the start and end markers
are only processed if the module named <EM>module name</EM> is compiled
in to Apache. The second format reverses the test, and only processes
the directives if <EM>module name</EM> is <STRONG>not</STRONG> compiled in.
<P>The <EM>module name</EM> argument is a module name as given as the file
name of the module, at the time it was compiled. For example,
<CODE>mod_rewrite.c</CODE>.
<P>&lt;IfModule&gt; sections are nest-able, which can be used to implement
simple multiple-module tests.
<P> <HR>
<H2><A name="include">Include directive</A></H2>
<STRONG>Syntax: (Apache 1.2)</STRONG> Include <EM>filename</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<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Include is only available in Apache 1.3 and later.
<P>
This directive allows inclusion of other configuration files from within the server configuration files.
<P> <HR>
<H2><A name="keepalive">KeepAlive directive</A></H2>
<STRONG>Syntax: (Apache 1.1)</STRONG> KeepAlive <EM>max-requests</EM><BR>
<STRONG>Default: (Apache 1.1)</STRONG> <CODE>KeepAlive 5</CODE><BR>
<STRONG>Syntax: (Apache 1.2)</STRONG> KeepAlive <EM>on/off</EM><BR>
<STRONG>Default: (Apache 1.2)</STRONG> <CODE>KeepAlive On</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> KeepAlive is only available in Apache
1.1 and later.<P>
This directive enables
<A HREF="/keepalive.html">Keep-Alive</A>
support.
<P><STRONG>Apache 1.1</STRONG>: Set <EM>max-requests</EM>
to the maximum number of requests you want Apache to entertain per
request. A limit is imposed to prevent a client from hogging your
server resources. Set this to <CODE>0</CODE> to disable support.
<P><STRONG>Apache 1.2 and later</STRONG>: Set to "On" to enable
persistent connections, "Off" to disable. See also the <A
HREF="#maxkeepaliverequests">MaxKeepAliveRequests</A> directive.</P><HR>
<H2><A name="keepalivetimeout">KeepAliveTimeout directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> KeepAliveTimeout <EM>seconds</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>KeepAliveTimeout 15</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> KeepAliveTimeout is only available in Apache
1.1 and later.<P>
The number of seconds Apache will wait for a subsequent request before
closing the connection. Once a request has been received, the timeout
value specified by the <A
HREF="#timeout"><CODE>Timeout</CODE></A> directive
applies.
<HR>
<H2><A name="limit">&lt;Limit&gt; directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt Limit} section directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A>
&lt;Limit <EM>method method</EM> ... &gt; ... &lt;/Limit&gt;<BR>
<A
HREF="directive-dict.html#Context"
REL="Help"
><STRONG>Context:</STRONG></A> any<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
&lt;Limit&gt; and &lt;/Limit&gt; are used to enclose a group of
access control directives which will then apply only to the specified
access methods, where <EM>method</EM> is any valid HTTP method.
Any directive except another &lt;Limit&gt; or
<A HREF="#directory">&lt;Directory&gt;</A> may be used; the majority will be
unaffected by the &lt;Limit&gt;. Example:
<BLOCKQUOTE><CODE>
&lt;Limit GET POST&gt;<BR>
require valid-user<BR>
&lt;/Limit&gt;</CODE></BLOCKQUOTE>
If an access control directive appears outside a &lt;Limit&gt;
directive, then it applies to all access methods. The method names
listed can be one or more of: GET, POST, PUT, DELETE, CONNECT or
OPTIONS. If GET is used it will also restrict HEAD requests.
<STRONG>If you wish to limit all methods, do not include any
&lt;Limit&gt; directive at all.</STRONG> <P><HR>
<H2><A name="listen">Listen directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A>
Listen [<EM>IP address</EM>:]<EM>port number</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<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> Listen is only available in Apache
1.1 and later.<P>
<P>The Listen directive instructs Apache to listen to more than one IP
address or port; by default it responds to requests on all IP
interfaces, but only on the port given by the <CODE><A
HREF="#port">Port</A></CODE> directive.</P>
<TT>Listen</TT> can be used instead of <TT><A
HREF="#bindaddress">BindAddress</A></TT> and <TT>Port</TT>. It tells
the server to accept incoming requests on the specified port or
address-and-port combination. If the first format is used, with a port
number only, the server listens to the given port on all interfaces,
instead of the port given by the <TT>Port</TT> directive. If an IP
address is given as well as a port, the server will listen on the
given port and interface. <P>
Note that you may still require a <TT>Port</TT> directive so
that URLs that Apache generates that point to your server still
work.<P>
Multiple Listen directives may be used
to specify a number of addresses and ports to listen to. The server
will respond to requests from any of the listed addresses and
ports.
<P>
For example, to make the server accept connections on both port
80 and port 8000, use:
<PRE>
Listen 80
Listen 8000
</PRE>
To make the server accept connections on two specified
interfaces and port numbers, use
<PRE>
Listen 192.170.2.1:80
Listen 192.170.2.5:8000
</PRE>
<P><STRONG>See Also:</STRONG>
<A HREF="/dns-caveats.html">DNS Issues</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="/misc/known_bugs.html#listenbug">Known Bugs</A></P>
<HR>
<H2><A NAME="listenbacklog">ListenBacklog directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> ListenBacklog <EM>backlog</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>ListenBacklog 511</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> ListenBacklog is only available in Apache
versions after 1.2.0.<P>
The maximum length of the queue of pending connections. Generally no
tuning is needed or desired, however on some systems it is desirable
to increase this when under a TCP SYN flood attack. See
the backlog parameter to the <CODE>listen(2)</CODE> system call.</P><HR>
<H2><A name="location">&lt;Location&gt; directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;Location <EM>URL</EM>&gt;
... &lt;/Location&gt;<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> Location is only available in Apache
1.1 and later.<P>
<P>The &lt;Location&gt; directive provides for access control by
URL. It is similar to the <A
HREF="#directory">&lt;Directory&gt;</A> directive, and
starts a subsection which is terminated with a &lt;/Location&gt;
directive. <CODE>&lt;Location&gt;</CODE> sections are processed in the
order they appear in the configuration file, after the
&lt;Directory&gt; sections and <CODE>.htaccess</CODE> files are
read, and after the &lt;Files&gt; sections.</P>
<p>Note that URLs do not have to line up with the filesystem at all,
it should be emphasized that &lt;Location&gt; operates completely outside
the filesystem.
<p>For all origin (non-proxy) requests, the URL to be matched is
of the form <code>/path/</code>, and you should not include any
<code>http://servername</code> prefix. For proxy requests, the URL
to be matched is of the form <code>scheme://servername/path</code>,
and you must include the prefix.
<p>The URL may use wildcards In a wild-card string, `?' matches any
single character, and `*' matches any sequences of characters.
<P><STRONG>Apache 1.2 and above:</STRONG>
Extended regular expressions can also be used, with the addition of
the <CODE>~</CODE> character.
For example:</P>
<PRE>
&lt;Location ~ &quot;/(extra|special)/data&quot;&gt;
</PRE>
<P>would match URLs that contained the substring "/extra/data" or
"/special/data". In Apache 1.3 and above, a new directive
<A HREF="#locationmatch">&lt;LocationMatch&gt;</A> exists which
behaves identical to the regex version of
<code>&lt;Location&gt;</code>.
<P>The <CODE>Location</CODE> functionality is especially useful when
combined with the <CODE><A
HREF="mod_mime.html#sethandler">SetHandler</A></CODE> directive. For example, to enable status requests, but allow them only
from browsers at foo.com, you might use:
<PRE>
&lt;Location /status&gt;
SetHandler server-status
order deny,allow
deny from all
allow from .foo.com
&lt;/Location&gt;
</PRE>
<p><strong>Apache 1.3 and above note about / (slash)</strong>: The slash character has special
meaning depending on where in a URL it appears. People may be used
to its behaviour in the filesystem where multiple adjacent slashes are
frequently collapsed to a single slash (i.e. <code>/home///foo</code>
is the same as <code>/home/foo</code>). In URL-space this is not
necessarily true. The <code>&lt;LocationMatch&gt;</code> directive
and the regex version of <code>&lt;Location&gt;</code> require you
to explicitly specify multiple slashes if that is your intention.
For example, <code>&lt;LocationMatch ^/abc&gt;</code> would match the
request URL <code>/abc</code> but not the request URL <code>//abc</code>.
The (non-regex) <code>&lt;Location&gt;</code> directive behaves
similarly when used for proxy requests. But when (non-regex)
<code>&lt;Location&gt;</code> is used for non-proxy requests it will
implicitly match multiple slashes with a single slash. For example,
if you specify <code>&lt;Location /abc/def&gt;</code> and the request
is to <code>/abc//def</code> then it will match.
<P>
<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
<HR>
<H2><A name="locationmatch">&lt;LocationMatch&gt;</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> &lt;LocationMatch <EM>regex</EM>&gt;
... &lt;/LocationMatch&gt;<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> Location is only available in Apache
1.3 and later.<P>
<P>The &lt;LocationMatch&gt; directive provides for access control by
URL, in an identical manner to <A
HREF="#location">&lt;Location&gt;</A>. However, it takes a regular
expression as an argument instead of a simple string. For example:</P>
<PRE>
&lt;LocationMatch &quot;/(extra|special)/data&quot;&gt;
</PRE>
<P>would match URLs that contained the substring "/extra/data" or
"/special/data".</P>
<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
<HR>
<H2><A NAME="lockfile">LockFile directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> LockFile <EM>filename</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>LockFile logs/accept.lock</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 LockFile directive sets the path to the lockfile used when
Apache is compiled with either USE_FCNTL_SERIALIZED_ACCEPT or
USE_FLOCK_SERIALIZED_ACCEPT. This directive should normally be
left at its default value. The main reason for changing it is if
the <CODE>logs</CODE> directory is NFS mounted, since <STRONG>the lockfile
must be stored on a local disk</STRONG>. The PID of the main
server process is automatically appended to the filename. <P>
<STRONG>SECURITY:</STRONG> It is best to avoid putting this file in a
world writable directory such as <CODE>/var/tmp</CODE> because someone
could create a denial of service attack and prevent the server from
starting by creating a lockfile with the same name as the one the
server will try to create.<P>
<P><HR>
<H2><A NAME="loglevel">LogLevel directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> LogLevel <EM>level</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>LogLevel error</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<BR>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> LogLevel is only available in 1.3 or later.
<P>LogLevel adjusts the verbosity of the messages recorded in the
error logs (see <A HREF="#errorlog">ErrorLog</A> directive).
The following <EM>level</EM>s are available, in order of
decreasing significance:
<P><TABLE>
<TR><TH ALIGN="LEFT"><STRONG>Level</STRONG>
<TH ALIGN="LEFT"><STRONG>Description</STRONG>
<TR><TH><TH ALIGN="LEFT"><STRONG>Example</STRONG>
<TR><TD><CODE>emerg</CODE>
<TD>Emergencies - system is unusable.
<TR><TD><TD>"Child cannot open lock file. Exiting"
<TR><TD><CODE>alert</CODE>
<TD>Action must be taken immediately.
<TR><TD><TD>"getpwuid: couldn't determine user name from uid"
<TR><TD><CODE>crit</CODE>
<TD>Critical Conditions.
<TR><TD><TD>"socket: Failed to get a socket, exiting child"
<TR><TD><CODE>error</CODE>
<TD>Error conditions.
<TR><TD><TD>"Premature end of script headers"
<TR><TD><CODE>warn</CODE>
<TD>Warning conditions.
<TR><TD><TD>"child process 1234 did not exit, sending another SIGHUP"
<TR><TD><CODE>notice</CODE>
<TD>Normal but significant condition.
<TR><TD><TD>"httpd: caught SIGBUS, attempting to dump core in ..."
<TR><TD><CODE>info</CODE>
<TD>Informational.
<TR><TD><TD>"Server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers)..."
<TR><TD><CODE>debug</CODE>
<TD>Debug-level messages
<TR><TD><TD>"Opening config file ..."
</TABLE>
<P>When a particular level is specified, messages from all other levels
of higher significance will be reported as well. E.g., when
<CODE>LogLevel info</CODE> is specified, then messages with log levels of
<CODE>notice</CODE> and <CODE>warn</CODE> will also be posted.
<P>
Using a level of at least <CODE>crit</CODE> is recommended.
<P><HR>
<H2><A name="maxclients">MaxClients directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt MaxClients} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> MaxClients <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>MaxClients 256</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 MaxClients directive sets the limit on the number of simultaneous
requests that can be supported; not more than this number of child server
processes will be created.<P><HR>
<H2><A name="maxkeepaliverequests">MaxKeepAliveRequests directive</A></H2>
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> MaxKeepAliveRequests <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>MaxKeepAliveRequests 100</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> Only available in Apache
1.2 and later.
<P>The MaxKeepAliveRequests directive limits the number of requests
allowed per connection when <A HREF="#keepalive">KeepAlive</A> is
on. If it is set to "<CODE>0</CODE>", unlimited requests will be
allowed. We recommend that this setting be kept to a high value for
maximum server performance.</P><HR>
<H2><A name="maxrequestsperchild">MaxRequestsPerChild directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt MaxRequestsPerChild} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> MaxRequestsPerChild <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>MaxRequestsPerChild 0</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 MaxRequestsPerChild directive sets the limit on the number of requests
that an individual child server process will handle. After MaxRequestsPerChild
requests, the child process will die. If MaxRequestsPerChild is 0, then
the process will never expire.<P>
Setting MaxRequestsPerChild to a non-zero limit has two beneficial effects:
<UL>
<LI>it limits the amount of memory that process can consume by (accidental)
memory leakage;
<LI> by giving processes a finite lifetime, it helps reduce the
number of processes when the server load reduces.
</UL><P><HR>
<H2><A name="maxspareservers">MaxSpareServers directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt MaxSpareServers} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> MaxSpareServers <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>MaxSpareServers 10</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 MaxSpareServers directive sets the desired maximum number of <EM>idle</EM>
child server processes. An idle process is one which is not handling
a request. If there are more than MaxSpareServers idle, then the parent
process will kill off the excess processes.<P>
Tuning of this parameter should only be necessary on very busy sites.
Setting this parameter to a large number is almost always a bad idea.<P>
This directive has no effect when used with the Apache Web server on a
Microsoft Windows platform.
<P>
See also <A HREF="#minspareservers">MinSpareServers</A> and
<A HREF="#startservers">StartServers</A>.<P><HR>
<H2><A name="minspareservers">MinSpareServers directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt MinSpareServers} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> MinSpareServers <EM>number</EM><BR>
<A
HREF="directive-dict.html#Default"
REL="Help"
><STRONG>Default:</STRONG></A> <CODE>MinSpareServers 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 MinSpareServers directive sets the desired minimum number of <EM>idle</EM>
child server processes. An idle process is one which is not handling
a request. If there are fewer than MinSpareServers idle, then the parent
process creates new children at a maximum rate of 1 per second.<P>
Tuning of this parameter should only be necessary on very busy sites.
Setting this parameter to a large number is almost always a bad idea.<P>
This directive has no effect on Microsoft Windows.
<P>
See also <A HREF="#maxspareservers">MaxSpareServers</A> and
<A HREF="#startservers">StartServers</A>.<P><HR>
<H2><A name="namevirtualhost">NameVirtualHost directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt NameVirtualHost} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> NameVirtualHost <EM>addr</EM>[:<EM>port</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>
<A
HREF="directive-dict.html#Compatibility"
REL="Help"
><STRONG>Compatibility:</STRONG></A> NameVirtualHost is only available in Apache 1.3 and later<P>
The NameVirtualHost directive is a required directive if you want to configure
<A HREF="/vhosts/index.html">name-based virtual hosts</A>.<P>
Although <EM>addr</EM> can be hostname it is recommended that you always use
an IP address, e.g.
<BLOCKQUOTE><CODE>NameVirtualHost 111.22.33.44</CODE></BLOCKQUOTE>
With the NameVirtualHost directive you specify the address to which your
name-based virtual host names resolve. If you have multiple name-based
hosts on multiple addresses, repeat the directive for each address.<P>
Note: the "main server" and any _default_ servers will <b>never</b>
be served for a request to a NameVirtualHost IP Address (unless for some
reason you specify NameVirtualHost but then don't define any VirtualHosts
for that address).<p>
Optionally you can specify a port number on which the name-based
virtual hosts should be used, e.g.
<BLOCKQUOTE><CODE>NameVirtualHost 111.22.33.44:8080</CODE></BLOCKQUOTE>
<STRONG>See also:</STRONG>
<A HREF="/vhosts/index.html">Apache Virtual Host documentation</A>
<H2><A name="options">Options directive</A></H2>
<!--%plaintext &lt;?INDEX {\tt Options} directive&gt; -->
<A
HREF="directive-dict.html#Syntax"
REL="Help"
><STRONG>Syntax:</STRONG></A> Options <EM>[+|-]option [+|-]option ...</EM><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#Override"
REL="Help"
><STRONG>Override:</STRONG></A> Options<BR>
<A
HREF="directive-dict.html#Status"
REL="Help"
><STRONG>Status:</STRONG></A> core<P>
The Options directive controls which server features are available in
a particular directory.
<P>
<EM>option</EM> can be set to <CODE>None</CODE>, in which case none of
the extra features are enabled, or one or more of the following:
<DL>
<DT>All
<DD>All options except for MultiViews.
<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.
<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.
<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 (e.g. 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.
</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"
(i.e. 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, i.e. 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>
If <CODE>require</CODE> appears in a <A HREF="#limit">&lt;Limit&gt;</A>
section, then it restricts access to the named methods, otherwise
it restricts access for all methods. Example:
<BLOCKQUOTE><CODE>
AuthType Basic<BR>
AuthName somedomain<BR>
AuthUserFile /web/users<BR>
AuthGroupFile /web/groups<BR>
&lt;Limit GET POST&gt;<BR>
require group admin<BR>
&lt;/Limit&gt;
</CODE></BLOCKQUOTE>
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.<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>
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>
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>
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="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 (i.e. 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, e.g.
<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 only
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.wibble.com</CODE></BLOCKQUOTE>
would be used if the canonical (main) name of the actual machine
were <CODE>monster.wibble.com</CODE>.<P>
<P><STRONG>See Also</STRONG>:<BR>
<A HREF="/dns-caveats.html">DNS Issues</A><BR>
<A HREF="#usecanonicalname">UseCanonicalName</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="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>
<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>Compatbility:</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</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, directory, .htaccess<BR>
<A HREF="directive-dict.html#Override" REL="Help">
<STRONG>Override:</STRONG></A> AuthConfig<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><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.<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>