Nginx won't send FIN ACK to PHP-FPM

dantes nginx-forum at nginx.us
Mon Aug 27 12:46:43 UTC 2012


Hey,

I have Rest API server powered by Nginx and PHP-FPM. Each API call produces
several CURL requests.

The script that executes the API calls, also utilizes CURL. I use curl multi
exec, with 1,000 threads. All the setup creates a little bit less than 10K
sockets.

Anyway, here is the problem...

The script that executes the API calls, let's say 3,000 on 1K threads. It
takes around 170 secs to finish processing all those API calls. However,
when the main script tries to return a response to the browser and initiate
a FIN_WAIT it takes 8 minutes until everything is returned to the browser.

Here is how it looks:
http://d.pr/i/1WkI

My theory is that it happens because Nginx puts the worker somehow on hold
or something like that. This was the first worker in the chain of workers.
There is no data being transferred since the worker initiated the request to
PHP-FPM.

Any ideas what should I do?

Thanks.

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,230145,230145#msg-230145



More information about the nginx mailing list