eaccelerator installation with litespeed

Discussion in 'PHP' started by aww, May 4, 2007.

  1. aww

    aww Well-Known Member

    I have been happily using eaccelerator with my cpanel install via this fantastic script here:
    ( http://tutorials.medialayer.com/cPanel/eaccelerator.sh )

    But of course this means I have no clue how to install it manually for litespeed :(

    Could anyone give me a general idea how to do it
    or even better, possibly hack that script so it will install for litespeed?

    By the way, are there any worries about running two copies of php/eaccelerator running as I want to keep my apache setup going for awhile, maybe even as a proxy to litespeed.
  2. mistwang

    mistwang LiteSpeed Staff

    If you are using our pre-built PHP binary or PHP 4.4.6, just run

    Then select eAccelerator, it will fetch our pre-built eAccelerator binary.

    If you use PHP 5, you need to build your own, just follow our wiki and eAccelerator installation instructions.
  3. aww

    aww Well-Known Member

    Oh that was embarrassingly easy.

    It even works with their stand alone control panel for eaccelerator.

    Their panel says the Caching is enabled but not the code optimizer. Is it safe to enable that?

    (update, it won't even let me enable the optimizer, always comes back as disabled)
  4. mistwang

    mistwang LiteSpeed Staff

    You probably need to enable the optimizer from lsws/php/php.ini, then do "killall lsphp".
  5. aww

    aww Well-Known Member

    Very nice. That did the trick.
    Do you think the control panel cannot see the files in the php cache because it's using /tmp/eacellerator? I am using a directory outside tmp for the apache eacel install.

    update: the control panel does not show the files because the allowed path is not set in php.ini

    You could almost integrate their new control panel into litespeed's - they look very similar, try it sometime:

    I must say I am rather impressed with LiteSpeed and it's ease of configuration (once I got some hints, thanks!)
    Last edited: May 5, 2007
  6. mistwang

    mistwang LiteSpeed Staff

    You can do that, just change the cache location in the php.ini .
  7. aww

    aww Well-Known Member

    I think there is something wrong with eaccelerator's behavior under litespeed?

    When I run wordpress through apache+php+eaccelerator I can see dozens of scripts stored in eaccelerator.

    When I run it now, I only see 4 scripts from other things I have run, not wordpress.


    I found the problem - wordpress+eaccelerator does not work right when PHP suEXEC is enabled (in fact I know PHP suEXEC causes several issues for several programs I used so I have disabled it)

    Now there are over a hundred files in eaccelerator cache :)

    I used to use the basedir file block in apache as a substitute for suexec. I wonder if it will work okay on litespeed?
    Last edited: May 5, 2007

Share This Page