Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Last revision Both sides next revision | ||
litespeed_wiki:cache:litemage:troubleshooting:no-cache-hit-header [2018/04/24 18:41] Lisa Clarke [No “X-LiteSpeed-Cache: hit,litemage” Header] Minor wording change |
litespeed_wiki:cache:litemage:troubleshooting:no-cache-hit-header [2018/08/07 18:33] Lisa Clarke Proofreading |
||
---|---|---|---|
Line 6: | Line 6: | ||
===== Do you see ''X-Litespeed-Cache: miss''? ===== | ===== Do you see ''X-Litespeed-Cache: miss''? ===== | ||
- | This header indicates 3 things: | + | This header indicates 4 things: |
+ | - LiteMage is working | ||
- It didn't find the page in the cache. | - It didn't find the page in the cache. | ||
- When it loaded the page to display this time, it also cached a copy. | - When it loaded the page to display this time, it also cached a copy. | ||
Line 44: | Line 45: | ||
Did you try flushing LiteMage Cache and Magento Cache Storage? Do so, and then reload the page a few times. | Did you try flushing LiteMage Cache and Magento Cache Storage? Do so, and then reload the page a few times. | ||
- | ===== Is there an ESI Header? ===== | + | ===== Have You Reached Your License's Cache Object Limit? ===== |
- | If you see the header ''x-litespeed-cache-control: esi=on'', then the page is cachable but it has encountered a problem. You may have reached your license's cache object limit. Another possible cause is a conflict with another cache solutions, such as CloudFlare. | + | If you see the header ''x-litespeed-cache-control: esi=on'', then the page is cachable, but it has encountered a problem. One possible reason is that LiteMage may have reached your license's cache object limit. You should check your Magento Admin LiteMage stats for details. |
+ | ===== Are You Using CDN Cache? ===== | ||
+ | |||
+ | CDN cache solutions, such as CloudFlare cache, Sucuri cache etc., may conflict with LiteMage. Please make sure to turn off CDN caches when using LiteMage. | ||
+ | |||
+ | This example shows CloudFlare cache enabled: | ||
{{:litespeed_wiki:cache:litemage:troubleshooting:litemage-cloudflare-incorrectcachesetting.png?direct&300}} | {{:litespeed_wiki:cache:litemage:troubleshooting:litemage-cloudflare-incorrectcachesetting.png?direct&300}} | ||
- | It's LiteMage's job to cache dynamic content, therefore, if you are going to use CloudFlare cache, it must be set up to only cache //static// content. See [[https://blog.litespeedtech.com/2017/11/20/magento-monday-litemage-cdns-and-tokens/|this blog post]] for more details. | + | Here's another example, where the user has turned on cache in Sucuri. In this case, you will always see ''x-litespeed-cache: miss'': |
+ | {{ :litespeed_wiki:cache:litemage:troubleshooting:litemage-cdn-cache-problem1.png?800 |}} | ||
+ | |||
+ | If you visit the backend directly with Sucuri, you can see LiteMage running fine with ''x-litespeed-cache: hit,litemage'': | ||
+ | {{ :litespeed_wiki:cache:litemage:troubleshooting:litemage-cdn-cache-problem2.png?500 |}} | ||
+ | |||
+ | It's LiteMage's job to cache dynamic content, therefore, if you are going to use CloudFlare/Sucuri cache, it must be set up to only cache //static// content. See [[https://blog.litespeedtech.com/2017/11/20/magento-monday-litemage-cdns-and-tokens/|this blog post]] for more details. | ||
===== Is There a Vary Cookie Issue? ===== | ===== Is There a Vary Cookie Issue? ===== | ||
Line 69: | Line 81: | ||
{{:litespeed_wiki:cache:litemage:troubleshooting:litemage-right-cookie-header-with-lscache-very-miss-hit.png?direct&800}} | {{:litespeed_wiki:cache:litemage:troubleshooting:litemage-right-cookie-header-with-lscache-very-miss-hit.png?direct&800}} | ||
+ | ===== Are There Cache-Related Rewrite Rules in .htaccess? ===== | ||
+ | Please don't place ''RewriteRule (.*) - [E=Cache-Control:no-cache]'' in your ''.htaccess'' file. In fact, don't place //any// rewrite-rule-based cache directives into ''.htaccess'', unless there is a wiki or KB article instructing you to do so. | ||
+ | |||
+ | Normally if you follow our wiki, LiteMage should work out of the box after installation, with no need to manually add anything. We have seen user-added rules break LiteMage and cause the cache miss header to display all the time. |