Can't enable cache

Discussion in 'Bug Reports' started by Michael.Terence, Feb 5, 2009.

  1. Michael.Terence

    Michael.Terence Active Member

    I've modified the cache settings in the server config menu.. I've tried setting the cache location to /tmp/lshttpd/cache and when that didn't work I set it to /var/cache/lsws but that doesn't work either. I have set max size to 1024, expire time to 3600, and the radio buttons are all set to yes.

    I have lsws setup to run as www-data:www-data and have chowned both the cache directories I listed above to that user:group, and even tried a chmod 777 on both directories. but still, nothing will show up in the folder.

    I have also setup the cache options at the vhost level thinking that may be it.

    There are no logs about it in the error log that I can see.

    Any help is appreciated :)
  2. Michael.Terence

    Michael.Terence Active Member

    update for anyone else that comes across this issue - mistwang posted that the cache functionality is only available with a 2cpu enterprise license. I have a 1cpu license, that's why it isn't working.

  3. closet geek

    closet geek Well-Known Member


    We are trialing the enterprise 2CPU license. LS is reading direct from our httpd.conf. We have taken all the relevant steps to enable the cache but nothing ever gets added to the directory.

    Any ideas?
  4. Michael.Terence

    Michael.Terence Active Member

    After I updated to the 2cpu license I didn't get anything in there for almost 2 days, even after doing the update license command from the terminal. - then, all of a sudden the cache enabled itself and broke all my sites (DOH!) - I had left it enabled, and everything set to yes.

    so.. uh, maybe just wait?
  5. closet geek

    closet geek Well-Known Member

    How did it break your sites? Did you notice any speed improvements with it? What did it do to server load?

  6. mistwang

    mistwang LiteSpeed Staff

    Make sure to enable the cache with Apache mod_cache directive

    CacheEnable ...

    Some site like vB, does not allow page being cached.
  7. closet geek

    closet geek Well-Known Member

    Can this be enabled at the server level not per vhost?
  8. mistwang

    mistwang LiteSpeed Staff

    Should be able to, give it a try.
  9. Michael.Terence

    Michael.Terence Active Member

    I can't answer the server load question, I didn't take a look. The box only runs a load of ~.10 typically (which I think is great, considering the high traffic clients I have on there).

    For my clients without a dedicated IP address, I use the vhost template functionality from the admin panel - I have forced gzip compression. All of my clients use Wordpress, and take advantage of the wp-super-cache plugin. With that plugin enabled, and the cache enabled you were greeted with double compressed pages, 502 errors, or 404 errors.

    There was also another issue: Client A has a private IP address - she uses WP to post deals, etc. When the cache enabled itself, all of a sudden when folks typed their domain name, they were actually seeing my family blog instead of her content. Her domain name was in the browser bar, and the request was going to her private IP address but (and this is just a thought - I didn't test it) the FIRST vhost (in this case in the DEFAULT php vhost template was being served instead of her content.

    This particular client's user/group has no access permissions to the vhost_root of my family blog - my only guess is that it was pulling it from cache.
  10. closet geek

    closet geek Well-Known Member

    Hmm doesn't sound like the cache feature is going to work very well in a shared hosting environment in this case.

    Thanks for your detailed reply.
  11. Michael.Terence

    Michael.Terence Active Member

    Not yet, - but I think it'll get worked out. :)
  12. mistwang

    mistwang LiteSpeed Staff

    Your problem probably is a configuration issue.

Share This Page