首页 > TroubleShooting > php官方不建议在httpd2.x环境下使用mpm-worker模式

php官方不建议在httpd2.x环境下使用mpm-worker模式

2011年10月22日 发表评论 阅读评论

  这个,不是apache官方的建议,而是php官方的建议,原文请看这里:http://php.net/manual/en/install.unix.apache2.php,至于为什么,还是请看php官网的faq:http://www.php.net/manual/en/faq.installation.php#faq.installation.apache2

Why shouldn’t I use Apache2 with a threaded MPM in a production environment?

PHP is glue. It is the glue used to build cool web applications by sticking dozens of 3rd-party libraries together and making it all appear as one coherent entity through an intuitive and easy to learn language interface. The flexibility and power of PHP relies on the stability and robustness of the underlying platform. It needs a working OS, a working web server and working 3rd-party libraries to glue together. When any of these stop working PHP needs ways to identify the problems and fix them quickly. When you make the underlying framework more complex by not having completely separate execution threads, completely separate memory segments and a strong sandbox for each request to play in, further weaknesses are introduced into PHP’s system.

If you want to use a threaded MPM, look at a FastCGI configuration where PHP is running in its own memory space.

分类: TroubleShooting 标签:
  1. 本文目前尚无任何评论.
  1. 本文目前尚无任何 trackbacks 和 pingbacks.