How to enable Nginx to serve PHP code/pages in Ubuntu

mike mike503 at
Tue Nov 4 23:46:19 MSK 2008

i personally verified that it is in fact recycling the processes
(where spawn-fcgi -never- recycled even after the default 500 or
whatever it was) and it also spawned 5 children exactly how i told it

i am curious to know why you say that.

also, i do consider php-fpm essential, otherwise i'd be managing
homebrew scripts to launch different fcgi pools (i have one per user)
with varying options and number of children, requests, etc. php-fpm
centralizes it and makes it very easy to use, graceful reloading, etc.
so no, i also disagree with your "not needed" statement. i tried
everything from apache + suexec + mod_fastcgi/mod_fcgid, mod_suphp,
spawn-fcgi, etc, etc. php-fpm was the cleanest method of managing all
the aspects i looked for, and will also soon introduce the apache
style process management which was one of the top two things i was
looking for.

On Tue, Nov 4, 2008 at 12:37 PM, Mark Alan <varia at> wrote:
> mike wrote:
>> respawn
>> exec /usr/bin/sudo -u mike /usr/local/bin/php-cgi -b 10500
> This will not work.
> php-cgi will not pick the values set by the env PHP_FCGI_ variables.
> It will neither spwan the 5 children, nor obey the max_requests directive.
> I leave it to you, as an exercise, to discover why.
> Could this be a reason why you need php-fpm where php-fpm is not needed?
> M.

More information about the nginx mailing list