Re:Apache 2 and PHP
by
Fweeky
·
· Score: 4, Interesting
PHP itself is thread safe (that's what the Thread Safe Resource Manager is all about); if your extension use is limited, it should work fine in a threaded MPM.
A better solution IMO is to use FastCGI; mod_fastcgi is thread safe, and it seperates PHP (and pretty much any other language) from the webserver so you can't make the webserver blow up with a badly written script, as well as using fewer resources since there's no need for a 1:1 mapping between webserver processes and PHP processes. You can even host your PHP on a seperate machine, or a cluster of them, without having to manage webservers on them all.
PHP itself is thread safe (that's what the Thread Safe Resource Manager is all about); if your extension use is limited, it should work fine in a threaded MPM.
A better solution IMO is to use FastCGI; mod_fastcgi is thread safe, and it seperates PHP (and pretty much any other language) from the webserver so you can't make the webserver blow up with a badly written script, as well as using fewer resources since there's no need for a 1:1 mapping between webserver processes and PHP processes. You can even host your PHP on a seperate machine, or a cluster of them, without having to manage webservers on them all.