Edit report at https://bugs.php.net/bug.php?id=62954&edit=1
ID: 62954
Comment by: jonas at brachium-system dot net
Reported by: jonas at brachium-system dot net
Summary: startup problems fpm / php-fpm
Status: Feedback
Type: Bug
Package: FPM related
Operating System: Linux
PHP Version: 5.3Git-2012-08-27 (Git)
Assigned To: fat
Block user comment: N
Private report: N
New Comment:
@David: Can you please explain, why an NGINX configuration option will solve
that startup problem?
Previous Comments:
------------------------------------------------------------------------
[2012-09-02 19:47:46] david at appliedautonomics dot com
Fixed on Debian Squeez via adding to fastcgi params:
fastcgi_buffer_size 16k;
fastcgi_buffers 4 16k;
------------------------------------------------------------------------
[2012-09-02 16:43:24] per at techspot dot com
This bug occurs more frequently on heavily loaded websites.
On my testserver it is difficult to reproduce with a low load.
But on my live server doing a "service php-fpm restart" makes it fail most
times.
For some reason the problem occurs less frequently in php-fpm 5.4.6 vs 5.3.16
opcode cachers also makes it occur more frequently, but it's possible to
reproduce with no opcode cacher loaded aswell, same rules as above for
frequency still apply (5.3 vs 5.4)
Output from testserver below running CentOS v6.3 with all patches applied and
php v5.4 via the remi repository:
http://rpms.famillecollet.com/enterprise/6/test/x86_64/
# php -v
PHP 5.4.6 (cli) (built: Aug 16 2012 14:26:39)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies
with XCache v2.0.1, Copyright (c) 2005-2012, by mOo
# DAEMON_COREFILE_LIMIT=unlimited strace -s1024 -f /etc/init.d/php-fpm restart
2>&1 | grep -i SEGV
[pid 3017] rt_sigaction(SIGSEGV, {0x7fddd5050730, [SEGV],
SA_RESTORER|SA_RESTART, 0x7fdddb55a920}, {SIG_DFL, [], 0}, 8) = 0
[pid 3017] rt_sigaction(SIGSEGV, {SIG_DFL, [SEGV], SA_RESTORER|SA_RESTART,
0x7fdddb55a920}, <unfinished ...>
[pid 3017] <... rt_sigaction resumed> {0x7fddd5050730, [SEGV],
SA_RESTORER|SA_RESTART, 0x7fdddb55a920}, 8) = 0
------------------------------------------------------------------------
[2012-09-02 09:07:29] jonas at brachium-system dot net
PHP 5.3.16-dev (fpm-fcgi) (built: Sep 2 2012 04:56:07)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
I have tried it with the current branch PHP-5.3.
It started two times correctly (Starts and detaches) after the second start the
problem occurs again.
So problem is not fixed - I have not tried 5.4 since fpm sapi is the same.
------------------------------------------------------------------------
[2012-09-01 19:41:16] [email protected]
I can't reproduce it here:
# /tmp/fpm/sbin/php-fpm -v
PHP 5.4.8-dev (fpm-fcgi) (built: Sep 1 2012 23:36:17) (DEBUG)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies
It starts, spawns its children and detaches from terminal with no problem at
all.
Can you try the latest snapshot and check if you still can reproduce the issue?
------------------------------------------------------------------------
[2012-08-27 22:54:12] al-php at none dot at
same problem here.
./configure --prefix=/<prefix>/ --enable-fpm --enable-bcmath --with-bz2
--enable-calendar --with-curl --enable-dba --enable-exif --enable-ftp
--enable-gd-native-ttf --with-jpeg-dir --with-png-dir --with-t1lib
--with-freetype-dir --with-gettext --enable-mbstring --with-mcrypt --with-mhash
--with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd
--enable-mysqlnd --with-openssl --with-pcre-regex --with-pspell --enable-shmop
--enable-soap --enable-sockets --enable-sysvmsg --enable-wddx --with-xsl
--enable-zip --with-zlib --with-tcadb --with-openssl-dir --with-gd
###
bin/php -v
PHP 5.4.5 (cli) (built: Aug 8 2012 01:03:00)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies
###
root@Ubuntu-1204-precise-64-minimal ~ # strace -fveall -p 2590 -p 2589
Process 2590 attached - interrupt to quit
Process 2589 attached - interrupt to quit
[pid 2589] wait4(-1, <unfinished ...>
[pid 2590] futex(0x7fc2a4d73720, FUTEX_WAIT_PRIVATE, 2, NULL
###
------------------------------------------------------------------------
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=62954
--
Edit this bug report at https://bugs.php.net/bug.php?id=62954&edit=1