499 Connection Responses, FastCGI, APC, nginx

Clint Priest cpriest at warpmail.net
Mon Oct 6 23:24:28 MSD 2008


There's something else going on here I think.  I've got 1000 php-cgi 
processes running, < 5% CPU utilization and I'm still getting 499's out 
of nginx.

What else could be causing this?  The debug logs show that the 
connection is being dropped (Connection reset by peer) from nginx to php-cgi


mike wrote:
> general rule of thumb is 1 request = 1 process, but it can serve more
> than one request per instance typically (within a second) it just
> depends on how long your requests take. if you have a slow script or
> database blocking, it will probably take up more than one request per
> second...
>
> On Mon, Oct 6, 2008 at 11:11 AM, Clint Priest <cpriest at warpmail.net> wrote:
>   
>> So if I want to support 1000 requests per second I need to have php-cgi with
>> 1000 child processes?
>>
>> This Response Code 499 that I'm getting, is that the only indicator that
>> I've run out of php-cgi slots?
>>
>> Igor Clark wrote:
>>
>> Hi,
>> On 6 Oct 2008, at 17:56, Clint Priest wrote:
>>
>> I'm getting ~50% 499 errors from nginx with $response_time ranging from .5s
>> to 32.78s and longer.  It seems related to fastcgi as I always get the file
>> immediately if its serving a static .htm file, never any delay or 499 codes.
>>
>> Any idea where I could go with this?  I've been trying things all morning
>> with out being able to find anything that fixes the issue.
>>
>> Some answers that may help me:
>>   1) How many simultaneous connections can one php-cgi instance support?
>>
>> Dependent on the number of children. 1 process = 1 connection.
>>
>>   2) Does anyone else run APC + FastCGI + nginx without problems?
>>
>> Yep. No problems at all.
>>
>>     2a) Is there any benefit or disadvantage to multiple php-cgi instances
>> w/ APC?
>>
>> Benefit: you can serve more than one request at a time, faster, because code
>> is cached.
>> Disadvantage: each instance now uses more memory.
>> cheers
>> i
>>
>>
>> Thanks!
>>
>> --
>> Clint Priest
>> cpriest at resultsgeneration.com
>> 660 4th Street, Suite 289
>> San Francisco, CA 94107
>> Cell: 415-724-6213
>> YIM/AIM: pkp9774
>> <RG-EmailSignatureLogo.gif>
>>
>> --
>> Igor Clark • POKE • 10 Redchurch Street • E2 7DD • +44 (0)20 7749 5355 •
>> www.pokelondon.com
>>
>>
>>
>>     





More information about the nginx mailing list