Bug #70740 [Fbk->Opn]: Opcache extension causes PHP process termination

From: Date: Mon, 26 Oct 2015 11:56:54 +0000
Subject: Bug #70740 [Fbk->Opn]: Opcache extension causes PHP process termination
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-196811@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=70740&edit=1

 ID:                 70740
 User updated by:    maly at myq dot cz
 Reported by:        maly at myq dot cz
 Summary:            Opcache extension causes PHP process termination
-Status:             Feedback
+Status:             Open
 Type:               Bug
 Package:            opcache
 Operating System:   Windows 10
 PHP Version:        5.6.15RC1
 Block user comment: N
 Private report:     N

 New Comment:

I have used default php ini configuration. The only diffs:
- Extension path was directed to the same directory as php.exe
- there was enabled only extension:
      zend_extension=php_opcache.dll
- opcache settings:
     [opcache]
     opcache.memory_consumption=128
     opcache.interned_strings_buffer=8
     opcache.max_accelerated_files=4000
     opcache.revalidate_freq=60
     opcache.fast_shutdown=1
     opcache.enable_cli=0

The PHP was executed via mod_fcgid in apache 2.2.29. Httpd.conf snippet:

   LoadModule fcgid_module modules/mod_fcgid.so
   AddHandler fcgid-script .php

   FcgidWrapper "\"C:/sw/MyQ/php/php/php-cgi.exe\"" .php
   

   AddType application/x-httpd-php .php
   FcgidMaxProcesses 20
   FcgidMaxRequestsPerProcess 490
   # PHP has max_execution_time=300, add 10 here to be sure 
   FcgidIOTimeout 310
   # PHP has 20M, add 1M here to be sure
   FcgidMaxRequestLen 22020096

   # Fix the opcache bug with tmp path
   FcgidInitialEnv TEMP "C:/WINDOWS/TEMP"
   FcgidInitialEnv TMP "C:/WINDOWS/TEMP

I executed many requests using utility ab:

   ab -n 1000 -6 http://127.0.0.1/test.php

Where the content of test.php was following:

   <?php
   $sec = 3;
   echo "waiting $sec s...";
   
   for($i=0; $i < $sec; ++$i) {
   	sleep(1);
   }
   
   echo "konec<br>";
   echo "cekalo se $sec sekund";

   phpinfo();

Note: The same behaviour appears even we use our internal php process manager. Our php process
manager is simple tool which preloads php processes, it uses (our implementation of) fast cgi to
communicate with php.


Previous Comments:
------------------------------------------------------------------------
[2015-10-26 11:32:15] ab@php.net

Ok, thanks for checking. Please post your ini and instructions to reproduce.

Thanks.

------------------------------------------------------------------------
[2015-10-25 16:18:55] maly at myq dot cz

I have tested the listed snapshot, and I have compiled my own relaese binaries from revision
36311ee4fd0ad33735ab0dc02f795b65888ca72d and must announce that the crashing still persists. The
stack is same as in previous step:

php_opcache.dll!accel_startup(_zend_extension * extension) Line 2599	C
php5.dll!zend_extension_startup(_zend_extension * extension) Line 154	C
php5.dll!zend_llist_apply_with_del(_zend_llist * l, int (void *) * func) Line 178	C
php5.dll!zend_startup_extensions(...) Line 175	C
php5.dll!php_module_startup(_sapi_module_struct * sf, _zend_module_entry * additional_modules,
unsigned int num_additional_modules) Line 2312	C
php-cgi.exe!php_cgi_startup(_sapi_module_struct * sapi_module) Line 942	C
php-cgi.exe!main(int argc, char * * argv) Line 1919	C
[External Code]	

Thanks for your time.

Best regards,
Petr Maly

------------------------------------------------------------------------
[2015-10-23 12:45:50] ab@php.net

Thanks for the trace, Petr. Could you please check whether this (or later) snap fixes the issue? http://windows.php.net/downloads/snaps/php-5.6/r22af882/
.

Otherwise I'd need your ini settings and maybe some description how to reproduce this.

Thanks.

------------------------------------------------------------------------
[2015-10-22 13:42:00] maly at myq dot cz

I have tested revision: 395ef4efb72aab6a660612be4632794f00991d85

I have generated several dumps and all crashes occured at the same location, see the stack:

php_opcache.dll!accel_startup(_zend_extension * extension) Line 2562	C
php5.dll!zend_extension_startup(_zend_extension * extension) Line 154	C
php5.dll!zend_llist_apply_with_del(_zend_llist * l, int (void *) * func) Line 178	C
php5.dll!zend_startup_extensions(...) Line 175	C
php5.dll!php_module_startup(_sapi_module_struct * sf, _zend_module_entry * additional_modules,
unsigned int num_additional_modules) Line 2239	C
php-cgi.exe!php_cgi_startup(_sapi_module_struct * sapi_module) Line 939	C
php-cgi.exe!main(int argc, char * * argv) Line 1915	C
[External Code]	

Thanks for your time.

Best regards,
Petr Maly

------------------------------------------------------------------------
[2015-10-20 09:52:56] ab@php.net

Thanks for the report. This looks like something else however, especially as you don't mention
the "base address". Could you please show the backtrace? This info can help on getting it
https://bugs.php.net/bugs-generating-backtrace-win32.php

Thanks.

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


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=70740


--
Edit this bug report at https://bugs.php.net/bug.php?id=70740&edit=1


Thread (10 messages)

« previous php.bugs (#196811) next »