php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #63097 Segfault on php-fpm service start
Submitted: 2012-09-16 01:25 UTC Modified: 2012-09-27 22:12 UTC
Votes:3
Avg. Score:4.3 ± 0.5
Reproduced:3 of 3 (100.0%)
Same Version:3 (100.0%)
Same OS:3 (100.0%)
From: admin at yqed dot com Assigned: fat (profile)
Status: Closed Package: FPM related
PHP Version: 5.3.17 OS: CentOS 5/6 64bits
Private report: No CVE-ID: None
 [2012-09-16 01:25 UTC] admin at yqed dot com
Description:
------------
This issue started making surface with PHP 5.3.15 and is still present in 5.3.17 
release. In /var/log/messages, you will see entries similar to:
hermes kernel: php-fpm[20659]: segfault at 00002aea5a750210 rip 0000003ca220da3e 
rsp 00007fff6b7d56b0 error 4

I created a objdump which will help you precisely locate the current issue.

Test script:
---------------
php-fpm.debug objdump file: http://www.mediafire.com/?qbkjzbidj9b1zsr


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-09-16 01:34 UTC] admin at yqed dot com
The error format I get when I restart the php-fpm service:
# service php-fpm restart
Stopping php-fpm:                                          [  OK  ]
Starting php-fpm: /bin/bash: line 1: 20659 Segmentation fault      /usr/sbin/php-
fpm -y /etc/php-fpm/php-fpm.conf
                                                           [FAILED]
 [2012-09-16 01:36 UTC] admin at qyqed dot com
The segfault occurs randomly, I can restart the service several times without 
issues. All of the sudden, it pops without explanation.
 [2012-09-16 02:15 UTC] admin at yqed dot com
Some additional troubleshooting:
# DAEMON_COREFILE_LIMIT=unlimited strace -s 1024 -f /etc/init.d/php-fpm restart 
2>&1 | grep -i SEGV
[pid 21884] --- SIGSEGV (Segmentation fault) @ 0 (0) ---
[pid 21883] <... wait4 resumed> [{WIFSIGNALED(s) && WTERMSIG(s) == SIGSEGV && 
WCOREDUMP(s)}], 0, NULL) = 21884

The above error occurs on a regular basis, no matter how many times I run the 
strace:
# DAEMON_COREFILE_LIMIT=unlimited strace -s 1024 -f /etc/init.d/php-fpm restart 
2>&1 | grep -i SEGV
[pid 21914] --- SIGSEGV (Segmentation fault) @ 0 (0) ---
[pid 21913] <... wait4 resumed> [{WIFSIGNALED(s) && WTERMSIG(s) == SIGSEGV && 
WCOREDUMP(s)}], 0, NULL) = 21914

I believe it could be related to this bug:
https://bugs.php.net/bug.php?id=61231
 [2012-09-17 02:46 UTC] debian at michael-neubert dot de
Hello,

since PHP 5.3.15 we have also segmentation faults when using xcache PHP module in 
combination with ionCubeLoader PHP module. 5.3.14 is not affected. Without loading 
xcache PHP module everything works also fine for us in 5.3.17.

Maybe this is also related to this bug: Bug https://bugs.php.net/bug.php?id=63005.

Best wishes
Michael
 [2012-09-27 22:11 UTC] fat@php.net
-Status: Open +Status: Feedback
 [2012-09-27 22:11 UTC] fat@php.net
Please try using this snapshot:

  http://snaps.php.net/php5.3-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

see bug #62886 and bug #62954
 [2012-09-27 22:12 UTC] fat@php.net
-Status: Feedback +Status: Closed -Assigned To: +Assigned To: fat
 [2012-09-27 22:12 UTC] fat@php.net
The fix for this bug has been committed.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.

see bug #62886 and bug #62954
 [2012-09-27 22:48 UTC] admin at yqed dot com
Can you please submit a patch related to this issue, so we can apply it on current 
production version? Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Mon Jun 21 13:01:23 2021 UTC