[BlueOnyx:08873] Re: Neat blog comparing PHP handlers

Michael Stauber mstauber at blueonyx.it
Thu Oct 20 09:59:56 -05 2011


Hi Jeff,

> Also the revelation that if you are using suPHP - Opcode type caches
> (xcache, APC, eAccellerator) will not work and therefore there is no
> benefit at all to run then.

Yeah, that's true. 

> The item goes on to say that FASTCGI can use Opcode caches, however the
> trade off is higher memory use.
> 
> Anyway - here's the item:
> 
> http://boomshadow.net/tech/php-handlers/

This is indeed a very good article. To me it doesn't reveal anything new, but 
it sums it up nicely on one page, so it is a good reference for explaining 
things whenever this topic comes up.

As you can see, all the different methods (DSO, CGI, suPHP, FastCGI) each have 
some benefits and some drawbacks. Unfortunately there is no "one size fits 
all" solution that has all the benefits.

On Blueonyx we have the choices between running sites with PHP through DSO or 
suPHP.

The lower memory usage and better security model make suPHP a much desired and 
welcome solution in a shared hosting environment. The drawback of course is 
higher CPU usage, slightly slower performance (than DSO) and (as you noticed) 
optional accelerators and caches won't really work.

For sites that require speedy execution, have a high CPU demand and would 
greatly benefit from accelerators, DSO is - at this time - the only 
alternative on BlueOnyx. Which of course is bought at the costs of lower 
security and the old UID/GID problems that such a site will have problems 
having the scripts upload or write files unless you carefully micro-manage the 
permissions and ownerships.

I'm not really comfortable of adding FastCGI to the mix of available options. 
FastCGI isn't "mainline" as far as CentOS is concerned. It's only served out 
of the "extras" YUM repository, which also contains a whole bag of troubles 
for us if enabled. Although it sure would incorporate some of the benefits of 
DSO with those of suPHP. At the cost of a higher memory usage and a much more 
complex GUI to manage it all. And the risk of things breaking during one YUM 
update or other, because the dependencies get all tangled up.

So yeah, as is one needs to carefully examine his needs and as of wether DSO 
or suPHP are the best choices for the site(s) in question.

-- 
With best regards

Michael Stauber



More information about the Blueonyx mailing list