php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #68058 Apache crashes on startup with recent master snapshots
Submitted: 2014-09-19 19:59 UTC Modified: 2014-12-30 10:42 UTC
From: mattficken@php.net Assigned: ab (profile)
Status: No Feedback Package: Apache2 related
PHP Version: master-Git-2014-09-19 (snap) OS: Windows
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2014-09-19 19:59 UTC] mattficken@php.net
Description:
------------
When trying to load Apache 2.4 OpenSSL-1.0.1 x86 VC11 with a master TS X86 VC11 snapshot, Apache crashes.

I'm loading apache to ultimately run a PHPT test, but the Apache/mod_php process crashes before it can run the test (so Apache/mod_php is now unusable with master snapshot builds on Windows).

It crashes in a different place on different snapshots/revisions, so may be either a memory (mis-)management/alignment(symbol change?) or binary compatibility issue.



standard minimalist Apache conf used (included below)

Test script:
---------------
LoadModule php5_module "C:/php-sdk/php-master-ts-windows-vc11-x86-r543ae3f/php7apache2_4.dll"
PHPIniDir "C:/php-sdk/temp/PFTT-ApacheManager-ELTPHISAII\"
LoadModule authz_core_module modules/mod_authz_core.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule mime_module modules/mod_mime.so
LoadModule dir_module modules/mod_dir.so
ServerAdmin administrator@10.30.68.150
ServerName 10.30.68.150:40111
Listen 10.30.68.150:40111
AcceptFilter http none
AcceptFilter https none
EnableMMAP off
EnableSendfile off
<Directory />
    AllowOverride none
</Directory>
DocumentRoot "C:\php-sdk\php-test-pack-master-ts-windows-vc11-x86-r551ee41"
<Directory "C:\php-sdk\php-test-pack-master-ts-windows-vc11-x86-r551ee41">
    Options Indexes FollowSymLinks
    AllowOverride None
    <IfModule mod_dir.c>
       DirectoryIndex index.html index.php
    </IfModule>
</Directory>
ErrorLog "C:\php-sdk\temp\PFTT-ApacheManager-ELTPHISAII\error.log"
LogLevel warn
<IfModule log_config_module>
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b\" common
</IfModule>
<IfModule mime_module>
    AddType application/x-httpd-php .php
</IfModule>

Actual result:
--------------
php-master-ts-windows-vc11-x86-r543ae3f
05a6e6c8 6cc9a3c4 php7ts!concat_function+0xde [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_operators.c @ 1535]
05a6e704 6cc9a586 php7ts!zend_binary_assign_op_helper_SPEC_CV_TMP+0x114 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 36924]
05a6e70c 6cc43ee8 php7ts!ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER+0x16 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 37040]
05a6e718 6ccad69b php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
05a6e7e0 6ccc0a42 php7ts!zend_call_function+0x79b [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 850]
05a6e878 6ce0d17b php7ts!zend_call_method+0x2a2 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_interfaces.c @ 101]
05a6e8c0 6ccad733 php7ts!zif_spl_autoload_call+0xfb [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\spl\php_spl.c @ 424]
05a6e978 6ccab919 php7ts!zend_call_function+0x833 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 869]
05a6ea04 6ccacb06 php7ts!zend_lookup_class_ex+0x389 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 1035]
05a6ea28 6cc4da47 php7ts!zend_fetch_class_by_name+0x26 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 1420]
05a6ea4c 6cc43ee8 php7ts!ZEND_FETCH_CLASS_SPEC_CONST_HANDLER+0x57 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 1517]
05a6ea58 6cc43e9f php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
05a6ea84 6cc124d3 php7ts!zend_execute+0x34f [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 381]
05a6eadc 6ccf2da7 php7ts!zend_execute_scripts+0x93 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend.c @ 1346]
05a6fce8 6d9937ae php7ts!php_execute_script+0x267 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\main\main.c @ 2560]
05a6fe00 6f9c2765 php7apache2_4!php_handler+0x58e [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\sapi\apache2handler\sapi_apache2.c @ 662]
05a6fe18 6f9c2bfe libhttpd!ap_run_handler+0x25
05a6fe30 6f9d23de libhttpd!ap_invoke_handler+0x9e
05a6fe50 6f9d2471 libhttpd!ap_die+0x3ae
05a6fe64 6f9ccef1 libhttpd!ap_die+0x441
05a6fe80 6f9ccf97 libhttpd!ap_psignature+0x13e1
05a6fe8c 6f9c5e65 libhttpd!ap_psignature+0x1487
05a6fea4 6f9e9fe3 libhttpd!ap_run_process_connection+0x25
05a6fecc 77873677 libhttpd!ap_regkey_value_remove+0x1183
05a6fed8 77d99d72 kernel32!BaseThreadInitThunk+0x12
05a6ff18 77d99d45 ntdll!RtlInitializeExceptionChain+0x63
05a6ff30 00000000 ntdll!RtlInitializeExceptionChain+0x36


php-master-ts-windows-vc11-x86-r551ee41
0523e0e8 6bf840b8 php7ts!ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER+0xd0 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 6148]
0523e0f4 6bfef6ce php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
0523e1c4 6c00190f php7ts!zend_call_function+0x7be [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 850]
0523e25c 6c14dd7b php7ts!zend_call_method+0x29f [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_interfaces.c @ 101]
0523e2a4 6bfef766 php7ts!zif_spl_autoload_call+0xfb [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\spl\php_spl.c @ 424]
0523e364 6bfed909 php7ts!zend_call_function+0x856 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 869]
0523e3f0 6bfeeb16 php7ts!zend_lookup_class_ex+0x389 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 1035]
0523e414 6bf928e3 php7ts!zend_fetch_class_by_name+0x26 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 1420]
0523e44c 6bf840b8 php7ts!ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER+0x33 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 4111]
0523e458 6bf8406e php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
0523e484 6bf52cd3 php7ts!zend_execute+0x30e [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 381]
0523e4dc 6c033d7a php7ts!zend_execute_scripts+0x93 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend.c @ 1293]
0523f6e8 6fe237ae php7ts!php_execute_script+0x23a [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\main\main.c @ 2567]
0523f800 6f9f2765 php7apache2_4!php_handler+0x58e [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\sapi\apache2handler\sapi_apache2.c @ 662]
0523f818 6f9f2bfe libhttpd!ap_run_handler+0x25
0523f830 6fa023de libhttpd!ap_invoke_handler+0x9e
0523f850 6fa02471 libhttpd!ap_die+0x3ae
0523f864 6f9fcef1 libhttpd!ap_die+0x441
0523f880 6f9fcf97 libhttpd!ap_psignature+0x13e1
0523f88c 6f9f5e65 libhttpd!ap_psignature+0x1487
0523f8a4 6fa19fe3 libhttpd!ap_run_process_connection+0x25
0523f8cc 75513677 libhttpd!ap_regkey_value_remove+0x1183
0523f8d8 77609d72 kernel32!BaseThreadInitThunk+0x12
0523f918 77609d45 ntdll!RtlInitializeExceptionChain+0x63
0523f930 00000000 ntdll!RtlInitializeExceptionChain+0x36


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2014-09-25 19:15 UTC] ab@php.net
-Status: Open +Status: Feedback
 [2014-09-25 19:15 UTC] ab@php.net
Matt,

I can currently reproduce some shutdown crashes, but none on start up. Could you please check the following:

- start apache with USE_ZEND_ALLOC=0 set on the environment, does it change something?
- is the same reproduceable on linux? Possibly use valgrind and USE_ZEND_ALLOC=0 as well

Thanks.
 [2014-09-25 19:16 UTC] ab@php.net
-Assigned To: +Assigned To: ab
 [2014-09-27 04:32 UTC] mattficken@php.net
USE_ZEND_ALLOC does make a difference!

Set to 0 or 1 it still crashes. Set to 1 and it crashes in different spot. Set to 0 and it crashes in the same spot.

This new crash is in soap ext, but really its the zend engine (as used by soap). See: http://git.php.net/?p=php-src.git;a=blob;f=ext/soap/soap.c;h=2b7566525d0323c72235b4eb2e2da4dc7400bacc;hb=refs/heads/master#l3090

USE_ZEND_ALLOC=1
05ade310 6e18cbcb php7ts!zend_parse_arg_impl+0x8f1 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_api.c @ 537]
05ade348 6e18cf17 php7ts!zend_parse_arg+0x3b [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_api.c @ 810]
05ade37c 6e185188 php7ts!zend_parse_va_args+0x277 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_api.c @ 985]
05ade398 6ddd3ed2 php7ts!zend_parse_parameters+0x68 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_api.c @ 1035]
05ade3ec 6e21d733 php_soap!zim_SoapClient___doRequest+0x62 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\soap\soap.c @ 3094]
05ade4a4 6e21cefa php7ts!zend_call_function+0x833 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 869]
05ade4e4 6e21ce75 php7ts!call_user_function_ex+0x7a [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 656]
05ade50c 6ddd5881 php7ts!call_user_function+0x25 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 637]
05ade5cc 6ddd5f91 php_soap!do_request+0x2d1 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\soap\soap.c @ 2599]
05ade74c 6ddd3918 php_soap!do_soap_call+0x591 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\soap\soap.c @ 2730]
05ade7c4 6e21d733 php_soap!zim_SoapClient___call+0x2f8 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\ext\soap\soap.c @ 2940]
05ade87c 6e230a42 php7ts!zend_call_function+0x833 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_execute_api.c @ 869]
05ade914 6e243ba3 php7ts!zend_call_method+0x2a2 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_interfaces.c @ 101]
05ade980 6e1bb834 php7ts!zend_std_call_user_call+0xc3 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_object_handlers.c @ 946]
05ade9bc 6e1b3ee8 php7ts!ZEND_DO_FCALL_SPEC_HANDLER+0x274 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 597]
05ade9c8 6e1b3e9f php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
05ade9f4 6e1824d3 php7ts!zend_execute+0x34f [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 381]
05adea4c 6e262da7 php7ts!zend_execute_scripts+0x93 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend.c @ 1346]
05adfc64 70f337ae php7ts!php_execute_script+0x267 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\main\main.c @ 2560]
05adfd7c 6fd22765 php7apache2_4!php_handler+0x58e [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\sapi\apache2handler\sapi_apache2.c @ 662]
05adfd94 6fd22bfe libhttpd!ap_run_handler+0x25
05adfdac 6fd323de libhttpd!ap_invoke_handler+0x9e
05adfdcc 6fd32471 libhttpd!ap_die+0x3ae
05adfde0 6fd2cef1 libhttpd!ap_die+0x441
05adfdfc 6fd2cf97 libhttpd!ap_psignature+0x13e1
05adfe08 6fd25e65 libhttpd!ap_psignature+0x1487
05adfe20 6fd49fe3 libhttpd!ap_run_process_connection+0x25
05adfe48 77223677 libhttpd!ap_regkey_value_remove+0x1183
05adfe54 77949d72 kernel32!BaseThreadInitThunk+0x12
05adfe94 77949d45 ntdll!RtlInitializeExceptionChain+0x63
05adfeac 00000000 ntdll!RtlInitializeExceptionChain+0x36


USE_ZEND_ALLOC=0 ... crashes in same place as before
0527ea20 6e4966c0 php7ts!add_string_to_string+0xe [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_operators.c @ 1494]
0527ea3c 6e453ee8 php7ts!ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER+0x30 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 27821]
0527ea48 6e453e9f php7ts!execute_ex+0x38 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 352]
0527ea74 6e4224d3 php7ts!zend_execute+0x34f [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend_vm_execute.h @ 381]
0527eacc 6e502da7 php7ts!zend_execute_scripts+0x93 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\zend\zend.c @ 1346]
0527fce0 706637ae php7ts!php_execute_script+0x267 [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\main\main.c @ 2560]
C:\Apache244-VC11-OpenSSL1.0.1e-x86\bin\libhttpd.dll - 
0527fdf8 6fae2765 php7apache2_4!php_handler+0x58e [c:\php-sdk\snap_master\vc11\x86\ts-windows-vc11-x86\sapi\apache2handler\sapi_apache2.c @ 662]
0527fe10 6fae2bfe libhttpd!ap_run_handler+0x25
0527fe28 6faf23de libhttpd!ap_invoke_handler+0x9e
0527fe48 6faf2471 libhttpd!ap_die+0x3ae
0527fe5c 6faecef1 libhttpd!ap_die+0x441
0527fe78 6faecf97 libhttpd!ap_psignature+0x13e1
0527fe84 6fae5e65 libhttpd!ap_psignature+0x1487
0527fe9c 6fb09fe3 libhttpd!ap_run_process_connection+0x25
0527fec4 75a93677 libhttpd!ap_regkey_value_remove+0x1183
0527fed0 77c59d72 kernel32!BaseThreadInitThunk+0x12
0527ff10 77c59d45 ntdll!RtlInitializeExceptionChain+0x63
0527ff28 00000000 ntdll!RtlInitializeExceptionChain+0x36
 [2014-12-30 10:42 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Apr 29 14:01:30 2024 UTC