php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #63950 Lot's of memory leaks detected
Submitted: 2013-01-09 08:43 UTC Modified: 2016-11-18 21:20 UTC
From: hufeng1987 at gmail dot com Assigned:
Status: Wont fix Package: APC (PECL)
PHP Version: 5.4.10 OS: CentOS 5.8
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: hufeng1987 at gmail dot com
New email:
PHP Version: OS:

 

 [2013-01-09 08:43 UTC] hufeng1987 at gmail dot com
Description:
------------
System	Linux localhost.localdomain 2.6.18-308.el5 #1 SMP Tue Feb 21 20:06:06 EST 
2012 x86_64
Build Date	Jan 8 2013 17:40:04
Configure Command	 './configure' '--prefix=/usr/local/webserver/php-with-
debug' '--with-iconv-dir=/usr/local' '--with-freetype-dir' '--with-jpeg-dir' '--
with-png-dir' '--with-zlib' '--with-libxml-dir=/usr' '--enable-xml' '--disable-
rpath' '--enable-bcmath' '--enable-shmop' '--enable-sysvsem' '--enable-inline-
optimization' '--with-curl' '--with-curlwrappers' '--enable-mbregex' '--enable-
fpm' '--enable-mbstring' '--with-gd' '--enable-gd-native-ttf' '--with-openssl' '--
enable-pcntl' '--enable-sockets' '--enable-zip' '--with-mcrypt' '--with-pdo-
mysql=mysqlnd' '--with-mysql=mysqlnd' '--enable-mysqlnd' '--enable-debug'

Expected result:
----------------
no memory leaks

Actual result:
--------------
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 608 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/cache/APC-3.1.13/apc_zend.c(38) :  Freeing 0x19D020A8 (25 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 4958 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/cache/APC-3.1.13/apc_compile.c(219) :  Freeing 0x19D086A0 (32 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 55 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(324) :  Freeing 0x19D08890 (72 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 941 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_compile.c(114) :  Freeing 0x19D08B80 (70 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 200 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/cache/APC-3.1.13/apc_compile.c(1787) :  Freeing 0x19D0A140 
(240 bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 1486 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(893) :  Freeing 0x19D0CF18 (64 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(339) : Actual location (location 
was relayed)"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 908 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(450) :  Freeing 0x19CCD2B8 (128 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 32 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_compile.c(2867) :  Freeing 0x19CDF848 
(240 bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(236) : Actual location (location 
was relayed)"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 10 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(292) :  Freeing 0x19C7B1E8 (64 
bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_alloc.c(2529) : Actual location 
(location was relayed)"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 10 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "[Wed 
Jan  9 16:40:10 2013]  Script:  '-'"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_compile.c(3309) :  Freeing 0x19C4DA08 
(64 bytes), script=-"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(339) : Actual location (location 
was relayed)"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "Last 
leak repeated 21 times"
[09-Jan-2013 16:40:10] WARNING: [pool www] child 2332 said into stderr: "=== 
Total 9240 memory leaks detected ==="


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-01-09 08:45 UTC] pajoye@php.net
-Status: Open +Status: Feedback
 [2013-01-09 08:45 UTC] pajoye@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc. If the script requires a 
database to demonstrate the issue, please make sure it creates 
all necessary tables, stored procedures etc.

Please avoid embedding huge scripts into the report.


 [2013-01-09 08:52 UTC] hufeng1987 at gmail dot com
i hope i could locate which code occurred these leak. but i failed because it 
run's too much more code. million lines of code running.

any suggestion help me find out the bad code? i tried my hard to find it out 
,but still got nothing.
--------------------------------------------------------------------------------
------------------------------------------------------
[09-Jan-2013 16:49:52.459798] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_hash.c(339) : Actual location (location was relayed)"
[09-Jan-2013 16:49:52.459810] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 849 times"
[09-Jan-2013 16:49:52.459822] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.459835] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/cache/APC-
3.1.13/apc_compile.c(219) :  Freeing 0x100EF5C0 (32 bytes), script=-"
[09-Jan-2013 16:49:52.459848] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 53 times"
[09-Jan-2013 16:49:52.459860] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.459872] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_compile.c(114) :  Freeing 0x100F0648 (54 bytes), script=-"
[09-Jan-2013 16:49:52.459885] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 182 times"
[09-Jan-2013 16:49:52.459897] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.459909] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_compile.c(2867) :  Freeing 0x100F17C8 (240 bytes), script=-"
[09-Jan-2013 16:49:52.459924] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_hash.c(236) : Actual location (location was relayed)"
[09-Jan-2013 16:49:52.459935] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 9 times"
[09-Jan-2013 16:49:52.459947] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.459958] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_hash.c(450) :  Freeing 0x100F29B0 (128 bytes), script=-"
[09-Jan-2013 16:49:52.459969] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 29 times"
[09-Jan-2013 16:49:52.459980] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.459991] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_vm_execute.h(380) :  Freeing 0x100F4198 (56 bytes), script=-"
[09-Jan-2013 16:49:52.460002] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_alloc.c(2529) : Actual location (location was relayed)"
[09-Jan-2013 16:49:52.460013] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 471 times"
[09-Jan-2013 16:49:52.460024] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "[Wed Jan  9 16:49:52 2013]  
Script:  '-'"
[09-Jan-2013 16:49:52.460035] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_compile.c(3309) :  Freeing 0x10493948 (64 bytes), script=-"
[09-Jan-2013 16:49:52.460056] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "/root/soft/phpall/php-
5.4.10/Zend/zend_hash.c(339) : Actual location (location was relayed)"
[09-Jan-2013 16:49:52.460069] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "Last leak repeated 21 times"
[09-Jan-2013 16:49:52.460080] WARNING: pid 2813, fpm_stdio_child_said(), line 
166: [pool www] child 2815 said into stderr: "=== Total 7991 memory leaks 
detected ==="
[09-Jan-2013 16:49:52.460091] DEBUG: pid 2813, fpm_event_loop(), line 411: event 
module triggered 1 events
 [2013-01-09 08:57 UTC] pajoye@php.net
An easy way to provide more info is to run php under valgrind. It could help to 
locate the issue (for obvious ones). But at the end we may need something to 
reproduce it.
 [2013-01-09 09:10 UTC] hufeng1987 at gmail dot com
i found following log

------------------------------------------------------------------------------

==3523==
==3523== HEAP SUMMARY:
==3523==     in use at exit: 1,712 bytes in 15 blocks
==3523==   total heap usage: 997,631 allocs, 997,616 frees, 333,021,308 bytes 
allocated
==3523==
==3523== Searching for pointers to 15 not-freed blocks
==3523== Checked 966,304 bytes
==3523==
==3523== 96 (16 direct, 80 indirect) bytes in 1 blocks are definitely lost in 
loss record 10 of 15
==3523==    at 0x4A0610C: malloc (vg_replace_malloc.c:195)
==3523==    by 0x8CDA128: ???
==3523==    by 0x8CF21A9: ???
==3523==    by 0x8CDD617: ???
==3523==    by 0x8CDE041: ???
==3523==    by 0x99D775: zend_startup_module_ex (zend_API.c:1661)
==3523==    by 0x9A96D2: zend_hash_apply (zend_hash.c:716)
==3523==    by 0x99DCBB: zend_startup_modules (zend_API.c:1788)
==3523==    by 0x8FDEC1: php_module_startup (main.c:2200)
==3523==    by 0xAFAA5B: php_cli_startup (php_cli.c:414)
==3523==    by 0xAFD368: main (php_cli.c:1344)
==3523==
==3523== LEAK SUMMARY:
==3523==    definitely lost: 16 bytes in 1 blocks
==3523==    indirectly lost: 80 bytes in 1 blocks
==3523==      possibly lost: 0 bytes in 0 blocks
==3523==    still reachable: 1,616 bytes in 13 blocks
==3523==         suppressed: 0 bytes in 0 blocks
==3523== Reachable blocks (those to which a pointer was found) are not shown.
==3523== To see them, rerun with: --leak-check=full --show-reachable=yes
==3523==
==3523== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 33 from 6)
--3523--
--3523-- used_suppression:     29 zlib-1.2.x trickyness (1a): See 
http://www.zlib.net/zlib_faq.html#faq36
--3523-- used_suppression:      4 dl-hack3
==3523==
==3523== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 33 from 6)
 [2013-01-09 15:44 UTC] rasmus@php.net
The Valgrind output looks normal. There are a couple of intentional at-exit leaks 
in APC. These are not relevant since they aren't per-request. It is simply memory 
only allocated at process startup and not freed, relying instead on process exit 
to clear it.
 [2013-01-09 23:52 UTC] hufeng1987 at gmail dot com
it's this APC bug? 

some times it cause PHP segmentation fault
 [2013-01-10 04:42 UTC] laruence@php.net
could you please give us the backtrace of the segfault you mentioned?
 [2013-01-10 04:46 UTC] hufeng1987 at gmail dot com
i have configured the core dump environment. still waiting for the core dump. it's 
not always segfault, i hope i could catch it . 

I want to ask, if some code  cause php segfault, it's code's problem or the php's 
problem?

should we fixed it by change the code ? or need to fixed by php upstream?
 [2013-01-10 04:46 UTC] hufeng1987 at gmail dot com
-Status: Feedback +Status: Open
 [2013-01-10 05:10 UTC] laruence@php.net
it depends on what the codes is, and whether it is a known issue.
 [2013-01-10 05:58 UTC] pajoye@php.net
-Status: Open +Status: Feedback
 [2013-01-10 05:58 UTC] pajoye@php.net
Disable APC and try again, that will clear this last question.
 [2013-01-10 06:23 UTC] hufeng1987 at gmail dot com
After disabled APC extension. the memory leaks reporting stopped. what is the 
matter? 

we really need APC , production environment need APC to boost the PHP 
performance.
 [2013-01-10 06:36 UTC] hufeng1987 at gmail dot com
I tried upgrade apc to 3.1.14. but failed at make test
-------------------------------------------------------------------------

=====================================================================
TIME END 2013-01-10 14:34:30

=====================================================================
TEST RESULT SUMMARY
---------------------------------------------------------------------
Exts skipped    :    0
Exts tested     :   42
---------------------------------------------------------------------

Number of tests :   56                55
Tests skipped   :    1 (  1.8%) --------
Tests warned    :    0 (  0.0%) (  0.0%)
Tests failed    :    6 ( 10.7%) ( 10.9%)
Expected fail   :    0 (  0.0%) (  0.0%)
Tests passed    :   49 ( 87.5%) ( 89.1%)
---------------------------------------------------------------------
Time taken      :   39 seconds
=====================================================================

=====================================================================
FAILED TEST SUMMARY
---------------------------------------------------------------------
APC: classes with namespaces (php 5.3) [tests/apc53_001.phpt]
APC: global spaces (php 5.3) [tests/apc53_002.phpt]
APC: closures (php 5.3) [tests/apc53_004.phpt]
APC: apc_store/fetch with objects [tests/apc_002.phpt]
APC: apc_store/fetch with objects (php 5.3) [tests/apc_003b.phpt]
APC: APCIterator formats [tests/iterator_006.phpt]
=====================================================================

You may have found a problem in PHP.
This report can be automatically sent to the PHP QA team at
http://qa.php.net/reports and http://news.php.net/php.qa.reports
This gives us a better understanding of PHP's behavior.
If you don't want to send the report immediately you can choose
option "s" to save it.  You can then email it to qa-reports@lists.php.net later.
Do you want to send this report now? [Yns]: Y

Please enter your email address.
(Your address will be mangled so that it will not go out on any
mailinglist in plain text): hufeng1987@gmail.com

Posting to http://qa.php.net/buildtest-process.php

Thank you for helping to make PHP better.
 [2013-01-10 06:39 UTC] aharvey@php.net
-Status: Feedback +Status: Open -Package: FPM related +Package: APC
 [2013-01-10 06:41 UTC] hufeng1987 at gmail dot com
After make install APC 3.1.14, i retried restart php-fpm. still got memory leaks 
report.
--------------------------------------------------------------------------------
-

[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h(380) :  Freeing 0x02D45858 
(56 bytes), script=-"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_alloc.c(2529) : Actual location 
(location was relayed)"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: "Last 
leak repeated 468 times"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: "[Thu 
Jan 10 14:39:42 2013]  Script:  '-'"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_compile.c(3309) :  Freeing 0x02D11E00 
(64 bytes), script=-"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: 
"/root/soft/phpall/php-5.4.10/Zend/zend_hash.c(339) : Actual location (location 
was relayed)"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: "Last 
leak repeated 21 times"
[10-Jan-2013 14:39:42] WARNING: [pool www] child 5997 said into stderr: "=== 
Total 7988 memory leaks detected ==="
 [2013-01-10 19:42 UTC] ab@php.net
I was playing with apc using apache, fpm and cli for several hours today. 
Unfortunately no result for this one as well as for #63909. The reproduce cases 
(config, php code) are definitely wanted for those two.
 [2013-01-14 02:38 UTC] hufeng1987 at gmail dot com
I got about 34 coredump files.
who want these files, please contact me .
and the backtrace file show like these:
---------------------------------------------------------------------
[root@localhost cores]# gdb /usr/local/webserver/php-with-debug/bin/php 
core.php-fpm.20313.localhost.localdomain.1357882491
GNU gdb (GDB) Red Hat Enterprise Linux (7.0.1-42.el5)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/local/webserver/php-with-debug/bin/php...done.

warning: core file may not match specified executable file.
[New Thread 20313]
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2

warning: no loadable sections found in added symbol-file system-supplied DSO at 
0x7fff815fd000
Core was generated by `php-fpm: pool www                                                             
'.
Program terminated with signal 11, Segmentation fault.
#0  0x00000000009d7910 in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8b7f8)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:603
603                             zend_error_noreturn(E_ERROR, "Non-static method 
%s::%s() cannot be called statically", fbc->common.scope->name, fbc-
>common.function_name);
(gdb) bt
#0  0x00000000009d7910 in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8b7f8)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:603
#1  0x00000000009dff99 in ZEND_DO_FCALL_SPEC_CONST_HANDLER (
    execute_data=0x2b9324b8b7f8)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:2235
#2  0x00000000009d6823 in execute (op_array=0x2c33060)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:410
#3  0x0000000000995bfe in zend_execute_scripts (type=8, retval=0x0,
    file_count=3) at /root/soft/phpall/php-5.4.10/Zend/zend.c:1309
#4  0x00000000008fe9cb in php_execute_script (primary_file=0x7fff815cbe50)
    at /root/soft/phpall/php-5.4.10/main/main.c:2482
#5  0x0000000000b0a075 in php_cli_server_dispatch_router (server=Cannot access 
memory at address 0xfffffffffffffe78
)
    at /root/soft/phpall/php-5.4.10/sapi/cli/php_cli_server.c:1949
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
(gdb)
 [2013-01-14 03:41 UTC] hufeng1987 at gmail dot com
you guys could download more coredump files about these problem.

i had upload it to goolgecode, please download it if you want to analyze them. 

totally contains 34 or more coredump files.

http://php-core-dump.googlecode.com/files/core-dump-20130114-Bug-63950.tgz
 [2013-01-14 09:36 UTC] laruence@php.net
there is a :
"warning: core file may not match specified executable".

Did you modify exe after it produced the core? Did you perhaps rebuild it with 
different command-line options? It is very important to give GDB the exact same 
binary that produced the core. If you don't, you'll get garbage out.
 [2013-01-14 09:40 UTC] hufeng1987 at gmail dot com
I am sure i had not modify any exe. i built PHP with debug on. then i waiting for 
coredump. nothing had changes in this peroid.

and there be so much more coredump. at lease 30 coredump files. i upload it to the  
googlecode. hope it will help for testing.

any other need i do ,just tell me how to do.
 [2013-01-14 09:47 UTC] hufeng1987 at gmail dot com
Here is the fresh coredump which generated in this afternoon, this is china 
.GMT+8.
--------------------------------------------------------------------------------

[root@localhost cores]# ls -l core.php-
fpm.10021.localhost.localdomain.1358144825
-rw------- 1 www www 215470080 01-14 14:27 core.php-
fpm.10021.localhost.localdomain.1358144825


--------------------------------------------------------------------------------
[root@localhost cores]# gdb /usr/local/webserver/php-with-debug/bin/php core.php                                                                                                                                   
-fpm.10021.localhost.localdomain.1358144825
GNU gdb (GDB) Red Hat Enterprise Linux (7.0.1-42.el5)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/local/webserver/php-with-debug/bin/php...done.

warning: core file may not match specified executable file.
[New Thread 10021]
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found).                                                                                                                                   
..done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2

warning: no loadable sections found in added symbol-file system-supplied DSO at                                                                                                                                    
0x7fff815fd000
Core was generated by `php-fpm: pool www                                                                                                                                                                                                
'.
Program terminated with signal 11, Segmentation fault.
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8bbf0)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:580
580             if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_A                                                                                                                                   
CC_DEPRECATED)) != 0)) {
(gdb) bt
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8bbf0)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:580
#1  0x00000000009dff99 in ZEND_DO_FCALL_SPEC_CONST_HANDLER (
    execute_data=0x2b9324b8bbf0)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:2235
#2  0x00000000009d6823 in execute (op_array=0x2e3b598)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:410
#3  0x0000000000995bfe in zend_execute_scripts (type=8, retval=0x0,
    file_count=3) at /root/soft/phpall/php-5.4.10/Zend/zend.c:1309
#4  0x00000000008fe9cb in php_execute_script (primary_file=0x7fff815cbe50)
    at /root/soft/phpall/php-5.4.10/main/main.c:2482
#5  0x0000000000b0a075 in php_cli_server_dispatch_router (server=Cannot access m                                                                                                                                   
emory at address 0xfffffffffffffe78
)
    at /root/soft/phpall/php-5.4.10/sapi/cli/php_cli_server.c:1949
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
 [2013-01-14 10:23 UTC] laruence@php.net
you need to get the backtrace exactly on that server which generated it.

please make sure there is no such warning:
"warning: core file may not match specified executable file."
 [2013-01-14 11:11 UTC] hufeng1987 at gmail dot com
[root@localhost cores]# gdb /usr/local/webserver/php-with-debug/sbin/php-fpm cor                                                                     
e.php-fpm.6280.localhost.localdomain.1358159315
GNU gdb (GDB) Red Hat Enterprise Linux (7.0.1-42.el5)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/local/webserver/php-with-debug/sbin/php-fpm...done.
[New Thread 6280]
Reading symbols from /lib64/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libcrypt.so.1
Reading symbols from /lib64/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libz.so.1
Reading symbols from /lib64/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/librt.so.1
Reading symbols from /usr/lib64/libmcrypt.so.4...(no debugging symbols found)...                                                                     
done.
Loaded symbols for /usr/lib64/libmcrypt.so.4
Reading symbols from /usr/lib64/libfreetype.so.6...(no debugging symbols found).                                                                     
..done.
Loaded symbols for /usr/lib64/libfreetype.so.6
Reading symbols from /usr/lib64/libpng12.so.0...(no debugging symbols found)...d                                                                     
one.
Loaded symbols for /usr/lib64/libpng12.so.0
Reading symbols from /usr/lib64/libjpeg.so.62...(no debugging symbols found)...d                                                                     
one.
Loaded symbols for /usr/lib64/libjpeg.so.62
Reading symbols from /usr/lib64/libcurl.so.3...(no debugging symbols found)...do                                                                     
ne.
Loaded symbols for /usr/lib64/libcurl.so.3
Reading symbols from /lib64/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libm.so.6
Reading symbols from /lib64/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libdl.so.2
Reading symbols from /lib64/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnsl.so.1
Reading symbols from /usr/lib64/libxml2.so.2...(no debugging symbols found)...do                                                                     
ne.
Loaded symbols for /usr/lib64/libxml2.so.2
Reading symbols from /lib64/libssl.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libssl.so.6
Reading symbols from /lib64/libcrypto.so.6...(no debugging symbols found)...done                                                                     
.
Loaded symbols for /lib64/libcrypto.so.6
Reading symbols from /usr/lib64/libgssapi_krb5.so.2...(no debugging symbols foun                                                                     
d)...done.
Loaded symbols for /usr/lib64/libgssapi_krb5.so.2
Reading symbols from /usr/lib64/libkrb5.so.3...(no debugging symbols found)...do                                                                     
ne.
Loaded symbols for /usr/lib64/libkrb5.so.3
Reading symbols from /usr/lib64/libk5crypto.so.3...(no debugging symbols found).                                                                     
..done.
Loaded symbols for /usr/lib64/libk5crypto.so.3
Reading symbols from /lib64/libcom_err.so.2...(no debugging symbols found)...don                                                                     
e.
Loaded symbols for /lib64/libcom_err.so.2
Reading symbols from /usr/lib64/libidn.so.11...(no debugging symbols found)...do                                                                     
ne.
Loaded symbols for /usr/lib64/libidn.so.11
Reading symbols from /lib64/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libc.so.6
Reading symbols from /lib64/libresolv.so.2...(no debugging symbols found)...done                                                                     
.
Loaded symbols for /lib64/libresolv.so.2
Reading symbols from /lib64/libpthread.so.0...(no debugging symbols found)...don                                                                     
e.
[Thread debugging using libthread_db enabled]
Loaded symbols for /lib64/libpthread.so.0
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found).                                                                     
..done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Reading symbols from /usr/lib64/libkrb5support.so.0...(no debugging symbols foun                                                                     
d)...done.
Loaded symbols for /usr/lib64/libkrb5support.so.0
Reading symbols from /lib64/libkeyutils.so.1...(no debugging symbols found)...do                                                                     
ne.
Loaded symbols for /lib64/libkeyutils.so.1
Reading symbols from /lib64/libselinux.so.1...(no debugging symbols found)...don                                                                     
e.
Loaded symbols for /lib64/libselinux.so.1
Reading symbols from /lib64/libsepol.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libsepol.so.1
Reading symbols from /usr/local/webserver/php-with-debug/lib/php/extensions/debu                                                                     
g-non-zts-20100525/apc.so...(no debugging symbols found)...done.
Loaded symbols for /usr/local/webserver/php-with-debug/lib/php/extensions/debug-                                                                     
non-zts-20100525/apc.so
Reading symbols from /usr/local/webserver/php-with-debug/lib/php/extensions/debu                                                                     
g-non-zts-20100525/memcached.so...(no debugging symbols found)...done.
Loaded symbols for /usr/local/webserver/php-with-debug/lib/php/extensions/debug-                                                                     
non-zts-20100525/memcached.so
Reading symbols from /usr/local/webserver/libmemcached/lib/libmemcached.so.8...d                                                                     
one.
Loaded symbols for /usr/local/webserver/libmemcached/lib/libmemcached.so.8
Reading symbols from /usr/lib64/libsasl2.so.2...(no debugging symbols found)...d                                                                     
one.
Loaded symbols for /usr/lib64/libsasl2.so.2
Reading symbols from /usr/lib64/libstdc++.so.6...(no debugging symbols found)...                                                                     
done.
Loaded symbols for /usr/lib64/libstdc++.so.6
Reading symbols from /lib64/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libgcc_s.so.1
Reading symbols from /lib64/libnss_files.so.2...(no debugging symbols found)...d                                                                     
one.
Loaded symbols for /lib64/libnss_files.so.2
Reading symbols from /usr/lib64/gconv/GB18030.so...(no debugging symbols found).                                                                     
..done.
Loaded symbols for /usr/lib64/gconv/GB18030.so

warning: no loadable sections found in added symbol-file system-supplied DSO at                                                                      
0x7fff815fd000
Core was generated by `php-fpm: pool www                                                                                                                                  
'.
Program terminated with signal 11, Segmentation fault.
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8b400)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:580
580             if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_A                                                                     
CC_DEPRECATED)) != 0)) {
(gdb) bt
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC (
    execute_data=0x2b9324b8b400)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:580
#1  0x00000000009dff99 in ZEND_DO_FCALL_SPEC_CONST_HANDLER (
    execute_data=0x2b9324b8b400)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:2235
#2  0x00000000009d6823 in execute (op_array=0x2e00370)
    at /root/soft/phpall/php-5.4.10/Zend/zend_vm_execute.h:410
#3  0x0000000000995bfe in zend_execute_scripts (type=8, retval=0x0,
    file_count=3) at /root/soft/phpall/php-5.4.10/Zend/zend.c:1309
#4  0x00000000008fe9cb in php_execute_script (primary_file=0x7fff815cbe50)
    at /root/soft/phpall/php-5.4.10/main/main.c:2482
#5  0x0000000000b0a075 in main (argc=6, argv=0x7fff815cc068)
    at /root/soft/phpall/php-5.4.10/sapi/fpm/fpm/fpm_main.c:1920
(gdb)
 [2013-01-15 03:07 UTC] hufeng1987 at gmail dot com
today's core dump backtrace.
---------------------------------------------------------------------------
[root@localhost cores]# gdb /usr/local/webserver/php-with-debug/sbin/php-fpm 
core.php-fpm.9686.localhost.localdomain.1358216229
GNU gdb (GDB) Red Hat Enterprise Linux (7.0.1-42.el5)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/local/webserver/php-with-debug/sbin/php-fpm...done.
[New Thread 9686]
Reading symbols from /lib64/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libcrypt.so.1
Reading symbols from /lib64/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libz.so.1
Reading symbols from /lib64/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/librt.so.1
Reading symbols from /usr/lib64/libmcrypt.so.4...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libmcrypt.so.4
Reading symbols from /usr/lib64/libfreetype.so.6...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libfreetype.so.6
Reading symbols from /usr/lib64/libpng12.so.0...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libpng12.so.0
Reading symbols from /usr/lib64/libjpeg.so.62...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libjpeg.so.62
Reading symbols from /usr/lib64/libcurl.so.3...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libcurl.so.3
Reading symbols from /lib64/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libm.so.6
Reading symbols from /lib64/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/libdl.so.2
Reading symbols from /lib64/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libnsl.so.1
Reading symbols from /usr/lib64/libxml2.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libxml2.so.2
Reading symbols from /lib64/libssl.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libssl.so.6
Reading symbols from /lib64/libcrypto.so.6...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libcrypto.so.6
Reading symbols from /usr/lib64/libgssapi_krb5.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libgssapi_krb5.so.2
Reading symbols from /usr/lib64/libkrb5.so.3...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libkrb5.so.3
Reading symbols from /usr/lib64/libk5crypto.so.3...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libk5crypto.so.3
Reading symbols from /lib64/libcom_err.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libcom_err.so.2
Reading symbols from /usr/lib64/libidn.so.11...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libidn.so.11
Reading symbols from /lib64/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libc.so.6
Reading symbols from /lib64/libresolv.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libresolv.so.2
Reading symbols from /lib64/libpthread.so.0...(no debugging symbols 
found)...done.
[Thread debugging using libthread_db enabled]
Loaded symbols for /lib64/libpthread.so.0
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Reading symbols from /usr/lib64/libkrb5support.so.0...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libkrb5support.so.0
Reading symbols from /lib64/libkeyutils.so.1...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libkeyutils.so.1
Reading symbols from /lib64/libselinux.so.1...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libselinux.so.1
Reading symbols from /lib64/libsepol.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libsepol.so.1
Reading symbols from /usr/local/webserver/php-with-
debug/lib/php/extensions/debug-non-zts-20100525/apc.so...(no debugging symbols 
found)...done.
Loaded symbols for /usr/local/webserver/php-with-debug/lib/php/extensions/debug-
non-zts-20100525/apc.so
Reading symbols from /usr/local/webserver/php-with-
debug/lib/php/extensions/debug-non-zts-20100525/memcached.so...(no debugging 
symbols found)...done.
Loaded symbols for /usr/local/webserver/php-with-debug/lib/php/extensions/debug-
non-zts-20100525/memcached.so
Reading symbols from 
/usr/local/webserver/libmemcached/lib/libmemcached.so.8...done.
Loaded symbols for /usr/local/webserver/libmemcached/lib/libmemcached.so.8
Reading symbols from /usr/lib64/libsasl2.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libsasl2.so.2
Reading symbols from /usr/lib64/libstdc++.so.6...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/libstdc++.so.6
Reading symbols from /lib64/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib64/libgcc_s.so.1
Reading symbols from /lib64/libnss_files.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/libnss_files.so.2
Reading symbols from /usr/lib64/gconv/GB18030.so...(no debugging symbols 
found)...done.
Loaded symbols for /usr/lib64/gconv/GB18030.so

warning: no loadable sections found in added symbol-file system-supplied DSO at 
0x7fff815fd000
Core was generated by `php-fpm: pool www                                                             
'.
Program terminated with signal 11, Segmentation fault.
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC 
(execute_data=0x2b9324b8b6d0) at /root/soft/phpall/php-
5.4.10/Zend/zend_vm_execute.h:580
580             if (UNEXPECTED((fbc->common.fn_flags & 
(ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) {
(gdb) bt
#0  0x00000000009d776a in zend_do_fcall_common_helper_SPEC 
(execute_data=0x2b9324b8b6d0) at /root/soft/phpall/php-
5.4.10/Zend/zend_vm_execute.h:580
#1  0x00000000009dff99 in ZEND_DO_FCALL_SPEC_CONST_HANDLER 
(execute_data=0x2b9324b8b6d0) at /root/soft/phpall/php-
5.4.10/Zend/zend_vm_execute.h:2235
#2  0x00000000009d6823 in execute (op_array=0x2d6aac0) at /root/soft/phpall/php-
5.4.10/Zend/zend_vm_execute.h:410
#3  0x0000000000995bfe in zend_execute_scripts (type=8, retval=0x0, 
file_count=3) at /root/soft/phpall/php-5.4.10/Zend/zend.c:1309
#4  0x00000000008fe9cb in php_execute_script (primary_file=0x7fff815cbe50) at 
/root/soft/phpall/php-5.4.10/main/main.c:2482
#5  0x0000000000b0a075 in main (argc=6, argv=0x7fff815cc068) at 
/root/soft/phpall/php-5.4.10/sapi/fpm/fpm/fpm_main.c:1920
(gdb)
 [2016-11-18 21:20 UTC] kalle@php.net
-Status: Open +Status: Wont fix
 [2016-11-18 21:20 UTC] kalle@php.net
APC is no longer supported in favor of opcache that comes bundled with PHP, if you wish to use the user cache, then look at PECL/APCu.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Dec 30 17:01:29 2024 UTC