ok
Direktori : /proc/thread-self/root/proc/self/root/usr/local/lsws/docs/ |
Current File : //proc/thread-self/root/proc/self/root/usr/local/lsws/docs/Cache_Help.html |
<!DOCTYPE html> <head> <meta charset="utf-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> <title>LiteSpeed Web Server Users' Manual - Page Cache Settings</title> <meta name="description" content="LiteSpeed Web Server Users' Manual - Page Cache Settings." /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="robots" content="noindex"> <link rel="shortcut icon" href="img/favicon.ico" /> <link rel="stylesheet" type="text/css" href="css/hdoc.css"> </head> <body> <div class="pagewrapper clearfix"><aside class="sidetree ls-col-1-5"> <figure> <img src="img/lsws_logo.svg" alt="lightspeed web server logo" width="100px"/> </figure> <h2 class="ls-text-thin"> LiteSpeed Web Server <br /> <span class="current"><a href="index.html">Users' Manual</a></span> </h2> <h3 class="ls-text-muted">Version 6.2 — Rev. 0</h3> <hr/> <div> <ul> <li><a href="license.html">License Enterprise</a></li> <li><a href="intro.html">Introduction</a></li> <li><a href="install.html">Installation</a></li> <li> <a href="admin.html">Administration</a> <ul class=" menu level2"> <li><a href="ServerStat_Help.html">Service Manager</a></li> </ul> </li> <li><a href="security.html">Security</a></li> <li> <a href="config.html">Configuration</a> <ul class="level2"> <li><a href="ServGeneral_Help.html">Server General</a></li> <li><a href="ServLog_Help.html">Server Log</a></li> <li><a href="ServTuning_Help.html">Server Tuning</a></li> <li><a href="ServSecurity_Help.html">Server Security</a></li> <li><span class="current"><a href="Cache_Help.html">Page Cache</a></span></li> <li><a href="PageSpeed_Config.html">PageSpeed Config</a></li> <li><a href="ExtApp_Help.html">External Apps</a></li> <ul class="level3"> <li><a href="External_FCGI.html">Fast CGI App</a></li> <li><a href="External_FCGI_Auth.html">Fast CGI Authorizer</a></li> <li><a href="External_LSAPI.html">LSAPI App</a></li> <li><a href="External_Servlet.html">Servlet Engine</a></li> <li><a href="External_WS.html">Web Server</a></li> <li><a href="External_PL.html">Piped logger</a></li> <li><a href="External_LB.html">Load Balancer</a></li> </ul> <li><a href="ScriptHandler_Help.html">Script Handler</a></li> <li><a href="PHP_Help.html">PHP</a></li> <li><a href="App_Server_Help.html">App Server Settings</a></li> <li><a href="Listeners_General_Help.html">Listener General</a></li> <li><a href="Listeners_SSL_Help.html">Listener SSL</a></li> <li><a href="Templates_Help.html">Virtual Host Templates</a></li> <li><a href="VirtualHosts_Help.html">Virtual Host Basic</a></li> <li><a href="VHGeneral_Help.html">Virtual Host General</a></li> <li><a href="VHSecurity_Help.html">Virtual Host Security</a></li> <li><a href="VHSSL_Help.html">Virtual Host SSL</a></li> <li> <a href="VHPageSpeed_Config.html">Virtual Host PageSpeed Config</a> </li> <li><a href="Rewrite_Help.html">Rewrite</a></li> <li><a href="Context_Help.html">Context</a></li> <ul class="level3"> <li><a href="Static_Context.html">Static Context</a></li> <li> <a href="Java_Web_App_Context.html">Java Web App Context</a> </li> <li><a href="Servlet_Context.html">Servlet Context</a></li> <li><a href="FCGI_Context.html">Fast CGI Context</a></li> <li><a href="LSAPI_Context.html">LSAPI Context</a></li> <li><a href="Proxy_Context.html">Proxy Context</a></li> <li><a href="CGI_Context.html">CGI Context</a></li> <li><a href="LB_Context.html">Load Balancer Context</a></li> <li><a href="Redirect_Context.html">Redirect Context</a></li> <li><a href="App_Server_Context.html">App Server Context</a></li> <li><a href="Rails_Context.html">Rack/Rails Context</a></li> </ul> <li><a href="VHAddOns_Help.html">Add-ons</a></li> </ul> </li> <li> <a href="webconsole.html">Web Console</a> <ul class="level2"> <li><a href="AdminGeneral_Help.html">Admin Console General</a></li> <li><a href="AdminSecurity_Help.html">Admin Console Security</a></li> <li> <a href="AdminListeners_General_Help.html"> Admin Listener General </a> </li> <li> <a href="AdminListeners_SSL_Help.html">Admin Listener SSL</a> </li> </ul> </li> </ul> </div> </aside> <article class="contentwrapper ls-col-3-5 clearfix"><div class="nav-bar ls-spacer-micro-top"><div class="prev">« <a href="ServSecurity_Help.html">Server Security</a></div><div class="center"><a href="config.html">Configuration</a></div><div class="next"><a href="PageSpeed_Config.html">PageSpeed Config</a> »</div></div> <h1>Page Cache Settings</h1><h2 id="top">Table of Contents</h2><section class="toc"><section class="toc-row"><header>Cache Storage Settings</header><p> <a href="#cacheEngine">Cache Features</a> | <a href="#cacheStorePath">Storage Path</a> | <a href="#litemage">Enable LiteMage</a> | <a href="#cacheMgrStorePath">Cache Manager Path</a> | <a href="#pubStoreExpireMinutes">Public Storage Expire (minutes)</a> | <a href="#purgeNoHitTimeout">No Hit Expire (minutes)</a></p></section> <section class="toc-row"><header>Cache Policy</header><p> <a href="#checkPublicCache">Check Public Cache</a> | <a href="#checkPrivateCache">Check Private Cache</a> | <a href="#respectCacheable">Respect Cacheable</a> | <a href="#cachePolicy:maxCacheObjSize">Max Object Size</a> | <a href="#cachePolicy:maxStaleAge">Cache Stale Age (seconds)</a> | <a href="#cachePolicy:cacheKeyMod">Cache Key Modifications</a> | <a href="#cachePolicy:expireInSeconds">Cache Expire Time (seconds)</a> | <a href="#cachePolicy:privateExpireInSeconds">Private Cache Expire Time (seconds)</a> | <a href="#cachePolicy:microCache5xx">Micro Cache 5XX Response</a> | <a href="#cachePolicy:enablePostCache">Enable POST cache</a></p></section> <section class="toc-row"><header>Do-Not-Cache URL</header><p> <a href="#noCacheUrl">Do-Not-Cache URL</a></p></section> <section class="toc-row"><header>Do-Not-Cache Domains</header><p> <a href="#noCacheDomain">No Cache Domain</a></p></section> </section> <section><div class="helpitem"><article class="ls-helpitem"><div><header id="cacheEngine"><h3>Cache Features<span class="ls-permlink"><a href="#cacheEngine"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies which cache features to enable. <span class="val">On</span> enables the cache engine while <span class="val">Crawler</span> and <span class="val">ESI</span> enables those respective features. Features enabled globally at the Server level can be overriden at the Virtual Host level.<br/><br/> Setting Enable LiteMage to <span class="val">On</span> at the Virtual Host level will override this setting, enabling all features.<br/><br/> Default value: Everything enabled</p> <h4>Syntax</h4><p>Select from checkbox</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cacheStorePath"><h3>Storage Path<span class="ls-permlink"><a href="#cacheStorePath"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies the directory for holding cached objects. Currently, LiteSpeed Cache stores each object in its own file. The filename is a hash of the object key. Multiple levels of directories will be created in order to avoid holding too many files in one directory. This value must be set at the Server level in order to enable cache. Virtual Host level settings will override Server level settings.</p> <h4>Syntax</h4><p>path</p> <h4>Tips</h4><p><span title="Performance" class="ls-icon-performance"></span> Assign a dedicated disk or disk array as the cache storage. RAID0 is recommended.<br/><br/> It is recommended to set a different cache storage path for each Virtual Host to prevent purge all requests from affecting other Virtual Hosts.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="litemage"><h3>Enable LiteMage<span class="ls-permlink"><a href="#litemage"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Enables LiteMage Cache for Magento Stores.<br/><br/> When set to 'On' the server will also try to use shared private cache information to speed up page load time for first time visitors. Select 'Safe' to disable this feature.</p> <h4>Syntax</h4><p>Select from drop down list</p> <h4>Tips</h4><p><span title="Information" class="ls-icon-info"></span> This setting will not work if your LiteSpeed license does not have the LiteMage module enabled.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cacheMgrStorePath"><h3>Cache Manager Path<span class="ls-permlink"><a href="#cacheMgrStorePath"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies the directory used to store cache manager files. These files are stored in <b>Storage Path</b> by default.</p> <h4>Syntax</h4><p>path</p> <h4>Tips</h4><p><span title="Performance" class="ls-icon-performance"></span> A separate location on a fast disk is recommended to prevent the accidental removal of cache manager files. Only set to a location on a RAM disk if cache storage is also saved on a RAM disk.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="pubStoreExpireMinutes"><h3>Public Storage Expire (minutes)<span class="ls-permlink"><a href="#pubStoreExpireMinutes"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>The maximum age of a cached file before the server will attempt to physically remove it. This removal operation will occur once per day to prevent cache storage from growing too large. Minimum setting is 60 minutes.</p> <h4>Syntax</h4><p>Integer number</p> <h4>Tips</h4><p><span title="Information" class="ls-icon-info"></span> Set this value to a time greater than your longest TTL to help prevent the removal of still valid cache files.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="purgeNoHitTimeout"><h3>No Hit Expire (minutes)<span class="ls-permlink"><a href="#purgeNoHitTimeout"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>The maximum number of minutes a cached file will remain in cache storage without a cache hit before being physically removed by the server. Set to 0 to disable this feature.<br/><br/> Default value: 0</p> <h4>Syntax</h4><p>Integer number</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="checkPublicCache"><h3>Check Public Cache<span class="ls-permlink"><a href="#checkPublicCache"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies whether to check against the public cache for URLs requested in the current context. Can be set at the server level, virtual host level, or context level.</p> <h4>Syntax</h4><p>Select from radio box</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="checkPrivateCache"><h3>Check Private Cache<span class="ls-permlink"><a href="#checkPrivateCache"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies whether to check against the private cache for URLs requested in the current context. Can be set at the server, virtual host, or context level.</p> <h4>Syntax</h4><p>Select from radio box</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="respectCacheable"><h3>Respect Cacheable<span class="ls-permlink"><a href="#respectCacheable"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Respect the value of regular "Cache-Control" response headers when LiteSpeed-specific cache control has not been provided.<br/><br/> LiteSpeed-specific cache control includes the X-litespeed-cache-control response header and the cache-control environment variable set via rewrite rule.</p> <h4>Syntax</h4><p>Select from radio box</p> <h4>Tips</h4><p><span title="Information" class="ls-icon-info"></span> This setting is enabled by default.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:maxCacheObjSize"><h3>Max Object Size<span class="ls-permlink"><a href="#cachePolicy:maxCacheObjSize"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies the maximum size of an object, up to 100M, that can be stored in the cache directory.<br/><br/> Default value: 10M</p> <h4>Syntax</h4><p>Integer number</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:maxStaleAge"><h3>Cache Stale Age (seconds)<span class="ls-permlink"><a href="#cachePolicy:maxStaleAge"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies how long an object will continue to be served from cache after it has expired but before a new cached copy is available. The default is "10" seconds.</p> <h4>Syntax</h4><p>Integer number</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:cacheKeyMod"><h3>Cache Key Modifications<span class="ls-permlink"><a href="#cachePolicy:cacheKeyMod"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Makes some requests more cache-friendly by allowing junk query string parameters to be dropped from URLs.</p> <h4>Syntax</h4><p><span class="val">clear</span> discards all previous configurations, <span class="val">-qs:[string]</span> drop all query strings where the name matches [string] exactly, or <span class="val">-qs:utm*</span> drop all query strings where the name part starts with [string]. Input one rule per line.</p> <h4>Example</h4><div class="ls-example"><span class="val">-qs:utm*</span> drops all query strings where the name part starts with "utm".<br/> <span class="val">-qs:gclid</span> drops all query strings where the name matches "gclid" exactly.</div></article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:expireInSeconds"><h3>Cache Expire Time (seconds)<span class="ls-permlink"><a href="#cachePolicy:expireInSeconds"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies how long an object will be cached. The default is "86400" seconds (one day).</p> <h4>Syntax</h4><p>Integer number</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:privateExpireInSeconds"><h3>Private Cache Expire Time (seconds)<span class="ls-permlink"><a href="#cachePolicy:privateExpireInSeconds"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies how long an object will be cached in private cache. The default is "60" seconds.</p> <h4>Syntax</h4><p>Integer number</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:microCache5xx"><h3>Micro Cache 5XX Response<span class="ls-permlink"><a href="#cachePolicy:microCache5xx"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Cache pages responding with HTTP status code 5xx (500, 503, etc) for 10 seconds when the cache response header indicates that the page is cacheable.<br/><br/> Default values:<br/> <b>Server level:</b> Yes<br/> <b>VH level:</b> Inherit Server level setting<br/> <b>Context-level</b> Inherit VH level setting</p> <h4>Syntax</h4><p>Select from radio box</p> <h4>Tips</h4><p><span title="Performance" class="ls-icon-performance"></span> Enabling this setting is useful for avoiding bad requests but can also act as some added DDoS protection.</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="cachePolicy:enablePostCache"><h3>Enable POST cache<span class="ls-permlink"><a href="#cachePolicy:enablePostCache"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>Specifies if POST requests can be cached using the "x-litespeed-cache-control" header.<br/><br/> Default value: <span class="val">No</span></p> <h4>Syntax</h4><p>Select from radio box</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="noCacheUrl"><h3>Do-Not-Cache URL<span class="ls-permlink"><a href="#noCacheUrl"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>A list of URL segments where any URL containing these listed segments will not be cached. String matching is used. Regular expressions are not supported. Can be set at the server or virtual host level. URL segments listed at the server level are inherited by all virtual hosts and added to their <b>Do-Not-Cache URL</b> lists.</p> <h4>Tips</h4><p><span title="Information" class="ls-icon-info"></span> You can add comments by starting a line with "#".</p> </article> </div> <div class="helpitem"><article class="ls-helpitem"><div><header id="noCacheDomain"><h3>No Cache Domain<span class="ls-permlink"><a href="#noCacheDomain"></a></span><span class="top"><a href="#top">⇑</a></span></h3></header></div><h4>Description</h4><p>A comma-separated list of domains that will not be cached.</p> <h4>Syntax</h4><p>Comma-separated list. Domain names are case insensitive and the leading "www." should be removed. The wildcard characters "*" and "?" are allowed. "?" only replaces one character. "*" replaces any number of characters. For example, "*.mydomain.com" will match all subdomains of mydomain.com. Duplicate domain names are not allowed.</p> </article> </div> </section> </article><div class="ls-col-1-1"><footer class="copyright">Copyright © 2003-2020. <a href="https://www.litespeedtech.com">LiteSpeed Technologies Inc.</a> All rights reserved.</footer> </div></div> </body> </html>