Edit report at https://bugs.php.net/bug.php?id=60961&edit=1
ID: 60961
Comment by: albertcasademont at gmail dot com
Reported by: phpbugs at oops dot mooo dot com
Summary: Graceful Restart (USR2) isn't very graceful
Status: Assigned
Type: Bug
Package: FPM related
Operating System: Debian Squeeze
PHP Version: 5.3.9
Assigned To: fat
Block user comment: N
Private report: N
New Comment:
Yes please, a graceful reload is needed urgently. And more generally, php-fpm needs some love
Previous Comments:
------------------------------------------------------------------------
[2017-01-02 16:28:50] konrad dot baumgart at moneyhouse dot de
This bug affects many people, but it seems the assigned person does not contribute to bugfixing
anymore.
Can we get it unassigned/reassigned?
Bug is still present with nginx 1.10 and php 7 communicating with unix socket
------------------------------------------------------------------------
[2015-06-05 11:22:45] razvanphp at yahoo dot com
I have the same problem with PHP 5.4.39-0+deb7u2, latest Debian Wheezy.
Nginx mainline 1.9 uses unix socket connection to php-fpm, but it results in 502 when reloading
php-fpm service.
Found this in the code, that seems to cause this:
static void sig_soft_quit(int signo) /* {{{ */
{
int saved_errno = errno;
/* closing fastcgi listening socket will force fcgi_accept() exit immediately */
close(0);
if (0 > socket(AF_UNIX, SOCK_STREAM, 0)) {
zlog(ZLOG_WARNING, "failed to create a new socket");
}
fpm_php_soft_quit();
errno = saved_errno;
}
------------------------------------------------------------------------
[2014-07-24 11:29:59] yinchuan at baixing dot com
CentOS 6.5 + Nginx 1.4.7 + PHP 5.4.9 with php-fpm
"fastcgi_keep_conn on;" in nginx.conf
set pm.max_request=100, then when thd 100th reqest reach, php process exit, and nginx log
error:"... recv() failed (104: Connection reset by peer) while reading response header from
upstream, client: XXX"
when set "fastcgi_keep_conn off;", everything is ok.
------------------------------------------------------------------------
[2014-02-19 19:35:47] ptr dot wang at gmail dot com
php5-fpm 5.5.8+dfsg-3+sury.org~precise+2 on ubuntu precise has the same problem.
killing USR2 signal to php5-fpm master process causes all php5-fpm processes (include the master
process) replaced, and the active requests end up with HTTP 502 Bad gateway error on the nginx side.
------------------------------------------------------------------------
[2013-09-18 16:22:53] baohx2000 at gmail dot com
Having this issue on 5.5.3. Sending USR2 to master process kills the master and
orphans the children. Have to then kill all children before I can restart the
master process.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=60961
--
Edit this bug report at https://bugs.php.net/bug.php?id=60961&edit=1