<html xmlns="http://www.w3.org/TR/xhtml1/strict"><head><!-- 
          XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
                This file is generated from xml source: DO NOT EDIT
          XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
        --><title>mod_cache- Apache HTTP Server</title><link href="../style/manual.css" type="text/css" rel="stylesheet"/></head><body><blockquote><div align="center"><img src="../images/sub.gif" alt="[APACHE DOCUMENTATION]"/><h3>Apache HTTP Server Version 2.0</h3></div><h1 align="center">Apache Module mod_cache</h1><table cellspacing="1" cellpadding="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td valign="top"><span class="help">Description:</span></td><td>Content cache keyed to URIs</td></tr><tr><td><a href="module-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td><a href="module-dict.html#ModuleIdentifier" class="help">Module&nbsp;Identifier:</a></td><td>cache_module</td></tr></table></td></tr></table><h2>Summary</h2>

<blockquote><table><tr><td bgcolor="#ffe5f5">
This module is experimental. Documentation is still under development...
</td></tr></table></blockquote>
    <p>mod_cache implements an RFC 2616 compliant HTTP content
    cache that can be used to cache either local or proxied content.
    mod_cache requires the services of one or more storage
    management modules. Two storage management modules are included in
    the base Apache distribution:</p>
    <dl>
    <dt><em>mod_disk_cache</em></dt>
    <dd>implements a disk based storage manager for use with mod_proxy</dd>
    <dt><em>mod_mem_cache</em></dt>
    <dd>implements an in-memory based storage manager. mod_mem_cache
    can be configured to operate in two modes: caching open file
    descriptors or caching objects in heap storage. <em>mod_mem_cache</em>
    is most useful when used to cache locally generated content or to cache 
    backend server content for mod_proxy configured for ProxyPass (aka <em>reverse proxy</em>)</dd>
    </dl>
    <p>Content stored and retrived keyed to the URL. Content with
    access protections is not cached.</p>
<h2>Directives</h2><ul><li><a href="#cachedefaultexpire">CacheDefaultExpire</a></li><li><a href="#cachedisable">CacheDisable</a></li><li><a href="#cacheenable">CacheEnable</a></li><li><a href="#cacheignorecachecontrol">CacheIgnoreCacheControl</a></li><li><a href="#cacheignorenolastmod">CacheIgnoreNoLastMod</a></li><li><a href="#cachelastmodifiedfactor">CacheLastModifiedFactor</a></li><li><a href="#cachemaxexpire">CacheMaxExpire</a></li><li><a href="#cacheon">CacheOn</a></li></ul><h2>Sample Configuration</h2>

<blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><p align="center"><strong>Sample httpd.conf</strong></p><code>

# <br>
# Sample Cache Configuration  <br>
# <br>
LoadModule cache_module modules/mod_cache.so  <br>
&lt;IfModule mod_cache.c&gt;<br>
   CacheOn On<br>
<p></p>
   #LoadModule disk_cache_module modules/mod_disk_cache.so <br>
   &lt;IfModule mod_disk_cache.c&gt; <br>
      CacheRoot c:/cacheroot <br>
      CacheSize 
      CacheEnable disk  / <br>
      CacheDirLevels 5 <br>
      CacheDirLength 3 <br>
   &lt;/IfModule&gt; <br>
<p></p>
   LoadModule mem_cache_module modules/mod_mem_cache.so <br>
   &lt;IfModule mod_mem_cache.c&gt; <br>
      MCacheEnable mem  / <br>
      MCacheSize 4096 <br>
      MCacheMaxObjectCount 100 <br>
      MCacheMinObjectSize 1 <br>
      MCacheMaxObjectSize 2048 <br>
   &lt;/IfModule&gt; <br>
<p></p>
&lt;/IfModule&gt; <br>

</code></td></tr></table></blockquote>

<hr/><h2><a name="CacheDefaultExpire">CacheDefaultExpire</a> <a name="cachedefaultexpire">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>The default time in seconds to cache a document.</p>
    <blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
    CacheDefaultExpire 86400
    </code></td></tr></table></blockquote>
<hr/><h2><a name="CacheDisable">CacheDisable</a> <a name="cachedisable">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>Disable caching of specified URLs by specified storage manager</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td>CacheDisable <em>cache_type </em> <em> url-string</em></td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>The <code class="directive">CacheDisable</code> directive instructs
    mod_cache to <em>not</em> cache urls at or above <em>url-string</em>.</p>

<blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><p align="center"><strong>Example</strong></p><code>
  CacheDisable disk /local_files
</code></td></tr></table></blockquote>
<hr/><h2><a name="CacheEnable">CacheEnable</a> <a name="cacheenable">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>Enable caching specified URLs in a specified storage manager</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td>CacheEnable <em>cache_type </em><em> url-string</em></td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>The <code class="directive">CacheEnable</code> directive instructs
    mod_cache to cache urls at or below <em>url-string</em>.  
    The cache store is specified with the <em>cache_type</em> argument.
    <em>cache_type </em> <em> mem</em> instructs mod_cache to use the
    in-memory cache storage manager implemented by <em>mod_mem_cache</em>. 
    <em>cache_type </em> <em> disk</em> instructs mod_cache to use the
    cache storage manager implemented by <em>mod_disk_cache </em>. </p>

<blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
  CacheEnable  disk  / <br>
  CacheEnable  mem   /manual <br>
  CacheEnable  fd    /images <br>
</code></td></tr></table></blockquote>
<hr/><h2><a name="CacheIgnoreCacheControl">CacheIgnoreCacheControl</a> <a name="cacheignorecachecontrol">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>Ignore requests from the client for uncached content</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>Ignore requests from the client for uncached content</p>

    <blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
    CacheIgnoreNoLastMod 
    </code></td></tr></table></blockquote>
<hr/><h2><a name="CacheIgnoreNoLastMod">CacheIgnoreNoLastMod</a> <a name="cacheignorenolastmod">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>Ignore responses where there is no Last Modified Header</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>Ignore responses where there is no Last Modified Header</p>

    <blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
    CacheIgnoreNoLastMod 
    </code></td></tr></table></blockquote>
<hr/><h2><a name="CacheLastModifiedFactor">CacheLastModifiedFactor</a> <a name="cachelastmodifiedfactor">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>The factor used to estimate the Expires date from the LastModified date</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>The factor used to estimate the Expires date from the LastModified date.</p>

    <blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
    CacheLastModifiedFactor  
    </code></td></tr></table></blockquote>
<hr/><h2><a name="CacheMaxExpire">CacheMaxExpire</a> <a name="cachemaxexpire">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td>The maximum time in seconds to cache a document</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>The maximum time in seconds to cache a document.</p>
    <blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
    CacheMaxExpire 604800
    </code></td></tr></table></blockquote>
<hr/><h2><a name="CacheOn">CacheOn</a> <a name="cacheon">Directive</a></h2><table cellpadding="1" cellspacing="0" border="0" bgcolor="#cccccc"><tr><td><table bgcolor="#ffffff"><tr><td nowrap="nowrap"><strong>Description: </strong></td><td/></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Syntax" class="help">Syntax:</a></td><td>CacheOn</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Context" class="help">Context:</a></td><td>server config</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Status" class="help">Status:</a></td><td>Experimental</td></tr><tr><td nowrap="nowrap"><a href="directive-dict.html#Module" class="help">Module:</a></td><td>mod_cache</td></tr></table></td></tr></table>
    <p>
    </p>


<blockquote><table cellpadding="10"><tr><td bgcolor="#eeeeee"><code>
  CacheOn
</code></td></tr></table></blockquote>
<hr/></blockquote><h3 align="center">Apache HTTP Server Version 2.0</h3><a href="./"><img src="../images/index.gif" alt="Index"/></a><a href="../"><img src="../images/home.gif" alt="Home"/></a></body></html>