3

The site use nginx+php-fpm. Today, accessing some pages returns 502 state in a few seconds (different from 502 caused by php script timeout), while other pages stay in service.

Status page of php-fpm shows all processes are active, but they're all stucked in State: finishing, and load of server is low.

pid:                  12775
state:                Finishing
start time:           18/May/2013:16:50:27 +0800
start since:          755
requests:             59
request duration:     743543095
request method:       GET
request URI:          /index.php
content length:       0
user:                 -
script:               /data/webserver/index.php
last request cpu:     0.00
last request memory:  0

I'm wondering why this happened, although it becomes well after I restart the php-fpm.

2
  • Hi Haocheng! I was having the same problem, some pages got stuck in finishing state, did you ever fix this? Dec 3, 2013 at 20:39
  • @BetoAveiga For me, it comes to be that the function registered by register_shutdown_function was stuck.
    – Haocheng
    Dec 9, 2013 at 12:59

1 Answer 1

0

This problem was caused by a long running function registered in fastcgi_finish_request(), after a long investigation. FYI if you're looking for the answer.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .