|
|

05-07-2009, 10:33 AM
|
|
LiteSpeed Staff
|
|
Join Date: May 2003
Location: New Jersey
Posts: 7,590
|
|
|
Max Obj Size of 1024 is too small I think. If a page larger than 1K, LSWS will not cache it. Cache Expire time should be shorter, start from 1-5 minutes, just in case that some page should not be cached was cached.
If you use cPanel, you should rebuild Apache with mod_cache support, then go to "service configuration >> Apache Configuration ", Edit Apache include files, edit "Pre Main Include", add
CacheRoot ...
CacheEnable disk /
It will enable cache for all vhosts configured through httpd.conf .
The reason to build Apache with mod_cache and mod_disk_cache is that, Apache will fail configuration test if not.
Yes, using faster disk will help with the performance.
Be conservative with cache configuration, only let web server to cache the page when the page can be cached. be extremely careful with the option that "Ignore Cache control headers".
|

05-14-2009, 03:03 PM
|
|
Member
|
|
Join Date: Jun 2008
Posts: 32
|
|
|
I've now rebuild Apache with mod_cache & mod_disk_cache
Then gone to cpanel / WHM, to "service configuration >> Apache Configuration ", Edit Apache include files, edit "Pre Main Include"
Then added two lines;
CacheRoot /backup/cache/
CacheEnable disk /
1st line is where the cache folder is.
In LSWS on the Configuration -> Cache
I have Max Object Size = 1024000
Enable Cache = Yes
Cache Expire Time (seconds) = 120
The rest of the settings;
Cache Request with Query String
Cache Request with Cookie
Cache Response with Cookie
Ignore Request Cache-Control
Ignore Response Cache-Control
I have left them as "Not Set"
The cache folder appears to be growing with some files.
What do you think of this now?
How do I check or monitor to see if this is working effectively or efficiently?
Any additional ideas/suggestions?
|

05-24-2009, 12:16 PM
|
|
New Member
|
|
Join Date: May 2009
Posts: 1
|
|
|
I'm only using our LSWS Server for reverse proxies and I am not seeing the cache working either.
I've enabled caching on the server level, vhost level, context level.
I set the cache store location.
Set the max size to 1024000
Set the expiration to 3600
I'm still seeing each connection go through to the ext app.
What am I missing?
|

05-24-2009, 02:02 PM
|
|
LiteSpeed Staff
|
|
Join Date: May 2003
Location: New Jersey
Posts: 7,590
|
|
|
The default cache policy is conservative, do not cache request/response with cookies, do not cache request/response when cache-control does not allow caching.
So, try a simple page like phpinfo() page first, on client side, check the request/response header with firebug to make sure there is no header that could prevent LSWS from caching the response.
Once phpinfo() page works, then you can start to check the other pages, and fine tune the cache policy carefully. It is not recommended to ignore the cache control header unless you know what you are doing and the page is safe to be cached.
|

05-25-2009, 08:50 PM
|
|
LiteSpeed Staff
|
|
Join Date: May 2003
Location: New Jersey
Posts: 7,590
|
|
|
If you think LSWS does not cache certain page, you need to check the request/response header see if anything prevent the page being cached.
Request with Query String? Request Cookie? Response Cookie? Request cache-control? response cache-control?
If you think a page can be safely cached even with some header can prevent it from being cached, you can adjust the cache policy to force LSWS to cache that page, you may need to create a context for that URL.
|

05-25-2009, 09:49 PM
|
|
Member
|
|
Join Date: Jun 2008
Posts: 32
|
|
|
(a) This is what we're using in LSWS;
Cache Storage Settings
---------------------
Storage Path = /backup/cache (using server's backup HD)
Max Object Size = 1024000
Cache Policy
-----------
Enable Cache = Yes
Cache Expire Time (seconds) = 120
Cache Request with Query String = No
Cache Request with Cookie = No
Cache Response with Cookie = No
Ignore Request Cache-Control = No
Ignore Response Cache-Control = No
(b) Then at WHM, Rebuild Apache with mod_cache & mod_disk_cache
(c) When done, again at WHM, went to;
Service configuration -> Apache Configuration
Edit Apache include files -> Pre Main Include
Selected Apache 2.x
Then added two lines;
CacheRoot /backup/cache/
CacheEnable disk /
The cache directory has been growing, therefore believe cache is working well.
Question now is there one of the menu sections in LSWS where I can see or monitor files or data cached Or better still is there a place in LSWS I can see the LSWS using the cache?
|

05-26-2009, 06:58 AM
|
|
LiteSpeed Staff
|
|
Join Date: May 2003
Location: New Jersey
Posts: 7,590
|
|
|
No, not possible to monitor the cache status at this moment. May add it to the real time report in the future release.
|

10-06-2009, 03:57 PM
|
|
Member
|
|
Join Date: Oct 2006
Posts: 17
|
|
|
Hi,
Does the VPS license have the cache feature enabled? We have a couple of VPS licenses installed and we cannot get any of them working.
LSWS cache settings are set. Apache directives are set. The cache directory is still empty.
How do we go about identifying the cause?
|

10-06-2009, 04:31 PM
|
|
LiteSpeed Staff
|
|
Join Date: May 2003
Location: New Jersey
Posts: 7,590
|
|
|
Cache function is only available for 2-CPU license and above. It is not available for VPS license.
|

10-06-2009, 05:42 PM
|
|
Member
|
|
Join Date: Oct 2006
Posts: 17
|
|
Thank you George. All sorted, caching is working beautifully. 
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -7. The time now is 06:02 AM.
|
|