Opcode Caches in suPHP

markb1439

Well-Known Member
#1
Hello,

I want to get the most effective opcode caching when running in suPHP mode. In another thread, it was said that eAccelerator is the best opcode cache to use with Litespeed. And, in WHM, it was advised to install eAccelerator using EasyApache.

However, that installs the latest version of eAccelerator, which only supports opcode caching but not user object caching. So much of the effectiveness is lost.

Can you tell me:

  • Is it still true that eAccelerator is recommended over APC when running suPHP? If APC is good, can you provide Litespeed-compatible installation instructions? I would prefer to use APC if possible, because of the limitation in the current version of eAccelerator. I would rather not have to rely on an old version of eA.
  • If eAccelerator is still the best choice, can you provide the recommended way to install eAccelerator with Litespeed in a way that takes advantage of user object caching. (Please include all steps including pruning of the cache directory.)
  • Whether it is also recommended to use memcache/memcached with eAccelerator or APC? If so, can you provide recommended Litespeed-compatible instructions?

Thanks and best regards,

Mark
 

webizen

Well-Known Member
#2
Except for older version of EA, none of opcode cache (EA, APC, xCache) would work with suPHP (Apache) or PHP suEXEC (LSWS) as php runs under different user id (shared hosting). you have to run them with PHP suEXEC disabled so that cache storage can be shared among all the vhost accounts.
 

markb1439

Well-Known Member
#3
Thank you. However, disabling suEXEC would be a significant security risk, right? So the best combination of security and performance would be suPHP/suEXEC + older version of eAccelerator, correct?

I have also heard some people say that memcache/memcached will work with suPHP. Is this true?

Thanks,

Mark
 

webizen

Well-Known Member
#4
for shared hosting environment, you need suEXEC enabled. for dedicated server, it is ok to disable suEXEC and run opcache (EA, APC, xCache, etc).

for best security and performance, use suEXEC (and LSWS cache if you would like) in share hosting environment.

memcache is not opcache but in-memory cache to store keyed object and can be shared among different servers. memcache works with both suEXEC environment and non-suEXEC environment.
 
Top