#43834 [Fbk-Opn]: zend_mm_shutdown - Apache Crash
ID: 43834 User updated by: jaco at jump dot co dot za Reported By: jaco at jump dot co dot za -Status: Feedback +Status: Open Bug Type: Scripting Engine problem Operating System: Windows 2003 PHP Version: 5.2CVS-2008-01-14 (snap) New Comment: I am unable to privide any code to re-produce this proplem. The best I could figure out up to know is that the get_browser() function together with the browscap.ini on windows on a busy website is not a good idea. The bug does not appear every time, but after I removed all get_browser() code from the site, the server did not crash again. We get about 500,000 page impressions per day, and the error occured about 10-15 times a day. Previous Comments: [2008-01-28 23:37:39] [EMAIL PROTECTED] 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. [2008-01-14 07:10:29] jaco at jump dot co dot za I got this in the user.dmp file: In user.dmp the assembly instruction at php5ts!_zend_mm_free_int+139 in C:\WINDOWS\system32\php5ts.dll from The PHP Group has caused an access violation exception (0xC005) when trying to read from memory location 0x697a6f59 on thread 7 [2008-01-14 06:45:43] jaco at jump dot co dot za I finally got the symbol files to work, and the stack trace looks a bit different now: function: php5ts!_zend_mm_free_int 006aac9b 33c9 xor ecx,ecx 006aac9d 8b4718 mov eax,[edi+0x18] 006aaca0 85c0 testeax,eax 006aaca2 0f95c1 setne cl 006aaca5 8d448f14 lea eax,[edi+ecx*4+0x14] 006aaca9 8b4c8f14 mov ecx,[edi+ecx*4+0x14] 006aacad 85c9 testecx,ecx 006aacaf 75e6 jnz php5ts!_zend_mm_free_int+0x117 (006aac97) 006aacb1 c702 mov dword ptr [edx],0x0 006aacb7 eb6f jmp php5ts!_zend_mm_free_int+0x1a8 (006aad28) FAULT -006aacb9 395f0c cmp [edi+0xc],ebx ds:0023:000c= 006aacbc 7505 jnz php5ts!_zend_mm_free_int+0x143 (006aacc3) 006aacbe 395908 cmp [ecx+0x8],ebx 006aacc1 7410 jz php5ts!_zend_mm_free_int+0x153 (006aacd3) 006aacc3 68cc629500 push0x9562cc 006aacc8 e883f6 callphp5ts!zend_mm_panic (006aa350) 006aaccd 8b4dfc mov ecx,[ebp-0x4] 006aacd0 83c404 add esp,0x4 006aacd3 894f0c mov [edi+0xc],ecx 006aacd6 897908 mov [ecx+0x8],edi 006aacd9 8b03 mov eax,[ebx] * Stack Back Trace * ChildEBP RetAddr Args to Child 0236fae0 006abce9 080dab18 0002 00755f17 php5ts!_zend_mm_free_int+0x139 (CONV: cdecl) 0236faec 00755f17 01253a20 0b936cac 00735f13 php5ts!_efree+0x39 (FPO: [1,0,0]) (CONV: cdecl) 0236faf8 00735f13 01253a78 0b936d20 0073a117 php5ts!_zval_dtor_func+0x27 (FPO: [1,0,1]) (CONV: cdecl) 0236fb04 0073a117 0b936cac 0b937348 0b927c00 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb1c 00755f49 0b927c60 0b937354 00735f13 php5ts!zend_hash_destroy+0x27 (FPO: [EBP 0x0b927a40] [1,0,4]) (CONV: cdecl) 0236fb28 00735f13 0b927c00 0b937420 0073a1a3 php5ts!_zval_dtor_func+0x59 (FPO: [1,0,1]) (CONV: cdecl) 0236fb34 0073a1a3 0b937354 0b925718 0236fc10 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb4c 006bce7b 0b927a40 0b91f89e php5ts!zend_hash_clean+0x23 (FPO: [EBP 0x0236fbb4] [1,0,4]) (CONV: cdecl) 0236fb94 006bc465 0236fbb4 080d98a0 006bc3e5 php5ts!zend_do_fcall_common_helper_SPEC+0xa0b (FPO: [EBP 0x0236fb98] [2,12,4]) (CONV: cdecl) 0236fba0 006bc3e5 0236fbb4 080d98a0 080d98a0 php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+0x15 (FPO: [2,0,0]) (CONV: cdecl) 0236fc28 0075b9fd 0008 080d98a0 php5ts!execute+0x1c5 (FPO: [EBP 0x0b920598] [2,16,3]) (CONV: cdecl) 0236fc58 006abca9 7c827d0b 0040 06f4 php5ts!php_execute_script+0x20d (CONV: cdecl) 0236fc5c 7c827d0b 0040 06f4 php5ts!_emalloc+0x39 (FPO: [1,0,0]) (CONV: cdecl) WARNING: Stack unwind information not available. Following frames may be wrong. 0236fc6c 77e61d43 08112da8 0236fcb8 ntdll!NtWaitForSingleObject+0xc
#43834 [NEW]: zend_mm_shutdown - Apache Crash
From: jaco at jump dot co dot za Operating system: Windows 2003 PHP version: 5.2CVS-2008-01-14 (snap) PHP Bug Type: Scripting Engine problem Bug description: zend_mm_shutdown - Apache Crash Description: On random apache crashes, the following is in the event log: Faulting application httpd.exe, version 2.2.4.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xadae. The fault address is always: 0xadae and 0xacb9 The following dump was created by dr watson: * State Dump for Thread Id 0xc68 * eax=030f011c ebx=016616f8 ecx=000a2168 edx=1a943ff8 esi=fe5415dc edi=0003 eip=006aadae esp=03c2fad0 ebp=03c2fae0 iopl=0 nv up ei ng nz ac pe cy cs=001b ss=0023 ds=0023 es=0023 fs=003b gs= efl=00010293 function: php5ts!zend_mm_shutdown 006aad93 8b03 mov eax,[ebx] 006aad95 8b4d0c mov ecx,[ebp+0xc] 006aad98 03c8 add ecx,eax 006aad9a 894d0c mov [ebp+0xc],ecx 006aad9d 8bf9 mov edi,ecx 006aad9f 8b4604 mov eax,[esi+0x4] 006aada2 a801 testal,0x1 006aada4 0f85a701 jne php5ts!zend_mm_shutdown+0x11e1 (006aaf51) 006aadaa 24fc and al,0xfc 006aadac 2bf0 sub esi,eax FAULT -006aadae 8b7e08 mov edi,[esi+0x8] ds:0023:fe5415e4= 006aadb1 8b5e0c mov ebx,[esi+0xc] 006aadb4 3bfe cmp edi,esi 006aadb6 0f85b400 jne php5ts!zend_mm_shutdown+0x1100 (006aae70) 006aadbc 3bde cmp ebx,esi 006aadbe 740d jz php5ts!zend_mm_shutdown+0x105d (006aadcd) 006aadc0 68cc629500 push0x9562cc 006aadc5 e886f5 callphp5ts!zend_mm_shutdown+0x5e0 (006aa350) 006aadca 83c404 add esp,0x4 006aadcd 8b5618 mov edx,[esi+0x18] 006aadd0 33c9 xor ecx,ecx * Stack Back Trace * ChildEBP RetAddr Args to Child WARNING: Stack unwind information not available. Following frames may be wrong. 03c2fae0 006abce9 1a9424d0 0003 00755f17 php5ts!zend_mm_shutdown+0x103e 77bbce33 e877ba20 b685 8508758b ac840ff6 php5ts!efree+0x39 e868186a 0xe877ba20 I have installed the latest snapshot, and this is still happening. Reproduce code: --- I am not able to reproduce this code, this only happens on the production server, with more than 4 million records in the database, every page I tested does not cause this to happen, so I am now thinking that this might be caused by specific data coming from mysql -- Edit bug report at http://bugs.php.net/?id=43834edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43834r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43834r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43834r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43834r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43834r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43834r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43834r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43834r=needscript Try newer version:http://bugs.php.net/fix.php?id=43834r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43834r=support Expected behavior:http://bugs.php.net/fix.php?id=43834r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43834r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43834r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43834r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43834r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43834r=dst IIS Stability:http://bugs.php.net/fix.php?id=43834r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43834r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43834r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43834r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43834r=mysqlcfg
#43834 [Opn]: zend_mm_shutdown - Apache Crash
ID: 43834 User updated by: jaco at jump dot co dot za Reported By: jaco at jump dot co dot za Status: Open Bug Type: Scripting Engine problem Operating System: Windows 2003 PHP Version: 5.2CVS-2008-01-14 (snap) New Comment: I finally got the symbol files to work, and the stack trace looks a bit different now: function: php5ts!_zend_mm_free_int 006aac9b 33c9 xor ecx,ecx 006aac9d 8b4718 mov eax,[edi+0x18] 006aaca0 85c0 testeax,eax 006aaca2 0f95c1 setne cl 006aaca5 8d448f14 lea eax,[edi+ecx*4+0x14] 006aaca9 8b4c8f14 mov ecx,[edi+ecx*4+0x14] 006aacad 85c9 testecx,ecx 006aacaf 75e6 jnz php5ts!_zend_mm_free_int+0x117 (006aac97) 006aacb1 c702 mov dword ptr [edx],0x0 006aacb7 eb6f jmp php5ts!_zend_mm_free_int+0x1a8 (006aad28) FAULT -006aacb9 395f0c cmp [edi+0xc],ebx ds:0023:000c= 006aacbc 7505 jnz php5ts!_zend_mm_free_int+0x143 (006aacc3) 006aacbe 395908 cmp [ecx+0x8],ebx 006aacc1 7410 jz php5ts!_zend_mm_free_int+0x153 (006aacd3) 006aacc3 68cc629500 push0x9562cc 006aacc8 e883f6 callphp5ts!zend_mm_panic (006aa350) 006aaccd 8b4dfc mov ecx,[ebp-0x4] 006aacd0 83c404 add esp,0x4 006aacd3 894f0c mov [edi+0xc],ecx 006aacd6 897908 mov [ecx+0x8],edi 006aacd9 8b03 mov eax,[ebx] * Stack Back Trace * ChildEBP RetAddr Args to Child 0236fae0 006abce9 080dab18 0002 00755f17 php5ts!_zend_mm_free_int+0x139 (CONV: cdecl) 0236faec 00755f17 01253a20 0b936cac 00735f13 php5ts!_efree+0x39 (FPO: [1,0,0]) (CONV: cdecl) 0236faf8 00735f13 01253a78 0b936d20 0073a117 php5ts!_zval_dtor_func+0x27 (FPO: [1,0,1]) (CONV: cdecl) 0236fb04 0073a117 0b936cac 0b937348 0b927c00 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb1c 00755f49 0b927c60 0b937354 00735f13 php5ts!zend_hash_destroy+0x27 (FPO: [EBP 0x0b927a40] [1,0,4]) (CONV: cdecl) 0236fb28 00735f13 0b927c00 0b937420 0073a1a3 php5ts!_zval_dtor_func+0x59 (FPO: [1,0,1]) (CONV: cdecl) 0236fb34 0073a1a3 0b937354 0b925718 0236fc10 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb4c 006bce7b 0b927a40 0b91f89e php5ts!zend_hash_clean+0x23 (FPO: [EBP 0x0236fbb4] [1,0,4]) (CONV: cdecl) 0236fb94 006bc465 0236fbb4 080d98a0 006bc3e5 php5ts!zend_do_fcall_common_helper_SPEC+0xa0b (FPO: [EBP 0x0236fb98] [2,12,4]) (CONV: cdecl) 0236fba0 006bc3e5 0236fbb4 080d98a0 080d98a0 php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+0x15 (FPO: [2,0,0]) (CONV: cdecl) 0236fc28 0075b9fd 0008 080d98a0 php5ts!execute+0x1c5 (FPO: [EBP 0x0b920598] [2,16,3]) (CONV: cdecl) 0236fc58 006abca9 7c827d0b 0040 06f4 php5ts!php_execute_script+0x20d (CONV: cdecl) 0236fc5c 7c827d0b 0040 06f4 php5ts!_emalloc+0x39 (FPO: [1,0,0]) (CONV: cdecl) WARNING: Stack unwind information not available. Following frames may be wrong. 0236fc6c 77e61d43 08112da8 0236fcb8 ntdll!NtWaitForSingleObject+0xc kernel32!WaitForSingleObjectEx+0xad Previous Comments: [2008-01-14 00:07:08] jaco at jump dot co dot za Description: On random apache crashes, the following is in the event log: Faulting application httpd.exe, version 2.2.4.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xadae. The fault address is always: 0xadae and 0xacb9 The following dump was created by dr watson: * State Dump for Thread Id 0xc68 * eax=030f011c ebx=016616f8 ecx=000a2168 edx=1a943ff8 esi=fe5415dc edi=0003 eip=006aadae esp=03c2fad0 ebp=03c2fae0 iopl=0 nv up ei ng nz ac pe cy cs=001b ss=0023 ds=0023 es=0023 fs=003b gs= efl=00010293 function: php5ts!zend_mm_shutdown 006aad93 8b03 mov eax,[ebx] 006aad95 8b4d0c mov ecx,[ebp+0xc] 006aad98 03c8 add ecx,eax 006aad9a 894d0c mov [ebp+0xc],ecx 006aad9d 8bf9 mov edi,ecx 006aad9f 8b4604 mov eax,[esi+0x4] 006aada2 a801 testal,0x1 006aada4 0f85a701 jne php5ts!zend_mm_shutdown+0x11e1 (006aaf51) 006aadaa 24fc and al,0xfc 006aadac 2bf0 sub esi,eax FAULT -006aadae 8b7e08 mov edi,[esi+0x8] ds:0023:fe5415e4= 006aadb1 8b5e0c mov ebx,[esi+0xc] 006aadb4 3bfe cmp edi,esi 006aadb6 0f85b400 jne php5ts!zend_mm_shutdown+0x1100
#43834 [Opn]: zend_mm_shutdown - Apache Crash
ID: 43834 User updated by: jaco at jump dot co dot za Reported By: jaco at jump dot co dot za Status: Open Bug Type: Scripting Engine problem Operating System: Windows 2003 PHP Version: 5.2CVS-2008-01-14 (snap) New Comment: I got this in the user.dmp file: In user.dmp the assembly instruction at php5ts!_zend_mm_free_int+139 in C:\WINDOWS\system32\php5ts.dll from The PHP Group has caused an access violation exception (0xC005) when trying to read from memory location 0x697a6f59 on thread 7 Previous Comments: [2008-01-14 06:45:43] jaco at jump dot co dot za I finally got the symbol files to work, and the stack trace looks a bit different now: function: php5ts!_zend_mm_free_int 006aac9b 33c9 xor ecx,ecx 006aac9d 8b4718 mov eax,[edi+0x18] 006aaca0 85c0 testeax,eax 006aaca2 0f95c1 setne cl 006aaca5 8d448f14 lea eax,[edi+ecx*4+0x14] 006aaca9 8b4c8f14 mov ecx,[edi+ecx*4+0x14] 006aacad 85c9 testecx,ecx 006aacaf 75e6 jnz php5ts!_zend_mm_free_int+0x117 (006aac97) 006aacb1 c702 mov dword ptr [edx],0x0 006aacb7 eb6f jmp php5ts!_zend_mm_free_int+0x1a8 (006aad28) FAULT -006aacb9 395f0c cmp [edi+0xc],ebx ds:0023:000c= 006aacbc 7505 jnz php5ts!_zend_mm_free_int+0x143 (006aacc3) 006aacbe 395908 cmp [ecx+0x8],ebx 006aacc1 7410 jz php5ts!_zend_mm_free_int+0x153 (006aacd3) 006aacc3 68cc629500 push0x9562cc 006aacc8 e883f6 callphp5ts!zend_mm_panic (006aa350) 006aaccd 8b4dfc mov ecx,[ebp-0x4] 006aacd0 83c404 add esp,0x4 006aacd3 894f0c mov [edi+0xc],ecx 006aacd6 897908 mov [ecx+0x8],edi 006aacd9 8b03 mov eax,[ebx] * Stack Back Trace * ChildEBP RetAddr Args to Child 0236fae0 006abce9 080dab18 0002 00755f17 php5ts!_zend_mm_free_int+0x139 (CONV: cdecl) 0236faec 00755f17 01253a20 0b936cac 00735f13 php5ts!_efree+0x39 (FPO: [1,0,0]) (CONV: cdecl) 0236faf8 00735f13 01253a78 0b936d20 0073a117 php5ts!_zval_dtor_func+0x27 (FPO: [1,0,1]) (CONV: cdecl) 0236fb04 0073a117 0b936cac 0b937348 0b927c00 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb1c 00755f49 0b927c60 0b937354 00735f13 php5ts!zend_hash_destroy+0x27 (FPO: [EBP 0x0b927a40] [1,0,4]) (CONV: cdecl) 0236fb28 00735f13 0b927c00 0b937420 0073a1a3 php5ts!_zval_dtor_func+0x59 (FPO: [1,0,1]) (CONV: cdecl) 0236fb34 0073a1a3 0b937354 0b925718 0236fc10 php5ts!_zval_ptr_dtor+0x23 (FPO: [1,0,1]) (CONV: cdecl) 0236fb4c 006bce7b 0b927a40 0b91f89e php5ts!zend_hash_clean+0x23 (FPO: [EBP 0x0236fbb4] [1,0,4]) (CONV: cdecl) 0236fb94 006bc465 0236fbb4 080d98a0 006bc3e5 php5ts!zend_do_fcall_common_helper_SPEC+0xa0b (FPO: [EBP 0x0236fb98] [2,12,4]) (CONV: cdecl) 0236fba0 006bc3e5 0236fbb4 080d98a0 080d98a0 php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+0x15 (FPO: [2,0,0]) (CONV: cdecl) 0236fc28 0075b9fd 0008 080d98a0 php5ts!execute+0x1c5 (FPO: [EBP 0x0b920598] [2,16,3]) (CONV: cdecl) 0236fc58 006abca9 7c827d0b 0040 06f4 php5ts!php_execute_script+0x20d (CONV: cdecl) 0236fc5c 7c827d0b 0040 06f4 php5ts!_emalloc+0x39 (FPO: [1,0,0]) (CONV: cdecl) WARNING: Stack unwind information not available. Following frames may be wrong. 0236fc6c 77e61d43 08112da8 0236fcb8 ntdll!NtWaitForSingleObject+0xc kernel32!WaitForSingleObjectEx+0xad [2008-01-14 00:07:08] jaco at jump dot co dot za Description: On random apache crashes, the following is in the event log: Faulting application httpd.exe, version 2.2.4.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xadae. The fault address is always: 0xadae and 0xacb9 The following dump was created by dr watson: * State Dump for Thread Id 0xc68 * eax=030f011c ebx=016616f8 ecx=000a2168 edx=1a943ff8 esi=fe5415dc edi=0003 eip=006aadae esp=03c2fad0 ebp=03c2fae0 iopl=0 nv up ei ng nz ac pe cy cs=001b ss=0023 ds=0023 es=0023 fs=003b gs= efl=00010293 function: php5ts!zend_mm_shutdown 006aad93 8b03 mov eax,[ebx] 006aad95 8b4d0c mov ecx,[ebp+0xc] 006aad98 03c8 add ecx,eax 006aad9a 894d0c mov [ebp+0xc],ecx 006aad9d 8bf9 mov edi,ecx 006aad9f 8b4604 mov eax,[esi+0x4] 006aada2 a801 testal,0x1 006aada4 0f85a701 jne php5ts
#43776 [NEW]: fsockopen crashes apache on windows
From: jaco at jump dot co dot za Operating system: Windows Server 2003 PHP version: 5.2.5 PHP Bug Type: Sockets related Bug description: fsockopen crashes apache on windows Description: Apache 2.2.4 PHP 5.2.5 whenever I use fsockopen, I get a message Error in my_thread_global_end(): 1 threads didn't exit in my apache log files. This happens when the threads are trying to be recycled. Steps to reproduce Start Apache Run ? $fp = fsockopen(192.168.1.105, 3306); fclose($fp); exit; ? Stop apache and the message apears in the apache error log. Reproduce code: --- $fp = fsockopen(192.168.1.105, 3306); fclose($fp); exit; Expected result: Clean Log File Actual result: -- Error in my_thread_global_end(): 1 threads didn't exit -- Edit bug report at http://bugs.php.net/?id=43776edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43776r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43776r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43776r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43776r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43776r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43776r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43776r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43776r=needscript Try newer version:http://bugs.php.net/fix.php?id=43776r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43776r=support Expected behavior:http://bugs.php.net/fix.php?id=43776r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43776r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43776r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43776r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43776r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43776r=dst IIS Stability:http://bugs.php.net/fix.php?id=43776r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43776r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43776r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43776r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43776r=mysqlcfg
#43776 [Opn]: fsockopen crashes apache on windows
ID: 43776 User updated by: jaco at jump dot co dot za Reported By: jaco at jump dot co dot za Status: Open Bug Type: Sockets related Operating System: Windows Server 2003 PHP Version: 5.2.5 New Comment: This is not happening when I run the script with CLI, no error is reported in CLI, its just when its on apache that it happens. Previous Comments: [2008-01-07 11:04:56] jaco at jump dot co dot za Description: Apache 2.2.4 PHP 5.2.5 whenever I use fsockopen, I get a message Error in my_thread_global_end(): 1 threads didn't exit in my apache log files. This happens when the threads are trying to be recycled. Steps to reproduce Start Apache Run ? $fp = fsockopen(192.168.1.105, 3306); fclose($fp); exit; ? Stop apache and the message apears in the apache error log. Reproduce code: --- $fp = fsockopen(192.168.1.105, 3306); fclose($fp); exit; Expected result: Clean Log File Actual result: -- Error in my_thread_global_end(): 1 threads didn't exit -- Edit this bug report at http://bugs.php.net/?id=43776edit=1
#41350 [Com]: Error in my_thread_global_end()
ID: 41350 Comment by: jaco at jump dot co dot za Reported By: graham at directhostinguk dot com Status: No Feedback Bug Type: MySQL related Operating System: Windows 2003 PHP Version: 5.2.3 New Comment: I was able to reproduce this on a very basic instalation: Apache 2.2.4 PHP 5.2.5 Windows 2003 Server NO Database installed ? $fp = fsockopen(192.168.1.105, 3312); fclose($fp) echo DONE; exit; ? This executes 100%, and gives no errors, but as soon as I stop apache, it gives me the message in the apache error log Error in my_thread_global_end(): 1 threads didn't exit So it seems to me more of a sockets problem than a mysql problem. When I run the same script in CLI, I get no error. Previous Comments: [2008-01-04 21:44:17] jaco at jump dot co dot za I am having the same and more problems. I am running: Apache 2.2.6 MySQL 5.0.45 PHP 5.2.5 Windows Server 2003 R2 Standard SP2 2 x Quad Core Xeon 4Gb RAM IIS Installed for SMTP, FTP and WWW on port 443 for a single .NET Webservice access (NO PHP connectors installed for IIS). But I am sure this is not IIS related, becuase it still happens even with IIS stopped Whenever apache tries to recycle threads I get: ** Apache Error Log ** [Fri Jan 04 22:37:38 2008] [notice] Child 324: All worker threads have exited. Error in my_thread_global_end(): 1 threads didn't exit exiting because it reached MaxRequestsPerChild. Signaling the parent to restart a new child process. [Fri Jan 04 22:37:42 2008] [notice] Parent: Received restart signal -- Restarting the server. Note the time difference between the first log and the last log This then causes my Apache to crash and restart. Then I tried to download the latest snapshot of PHP, installed it, but then Apache woould not start at all, just gives me a starting status, but does not het out of it. My problem is also that there is hundreds of php files running and our site is very active, and I have NO idea what is causing this problem. The PHP error log is clean, but the following also shows up AFTER apache crashes. 080104 11:24:26 [Warning] Aborted connection 16865 to db: '' user: '*' host: 'localhost' (Got an error reading communication packets) But I am sure that this is just caused by apache that have crashed and the already open calls to the database that was not terminated by the php script. These messages apears in the event log after the crash: Faulting application httpd.exe, version 2.2.6.0, faulting module libapr-1.dll, version 1.2.11.0, fault address 0x79a0. Faulting application httpd.exe, version 2.2.6.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xacb9. We are using both mysql and mysqli connectors and I have tried to download the ones from the mysql site and again apache refused to start. This is quite serious for us at the moment, becuase its in a live enviroment and the dev servers never had this problem. Hope we can find a solution soon. [2008-01-04 18:28:12] jcmelcher at gmail dot com This worked for me... IIS 6.0 with PHP 5.2.5 on Win2K3 SP2 If you download the latest PHP - MySQL connector files direct from MySQL this problem goes away:- http://dev.mysql.com/downloads/connector/php/ [2008-01-04 14:30:55] benjamin dot azan at gmail dot com I could not find the new version of mysql connector but I changed the PHP mode from CGI/fastCGI to Apache 2.0 Handler and it fixed the problem. [2008-01-04 11:54:05] benjamin dot azan at gmail dot com The mySQL bug http://bugs.mysql.com/bug.php?id=25621 says : MySQL 5.0.54BK on WinXP localhost does not exhibit the error. and the PHP 5.2.5 show Client API version 5.0.45 So I think the next version of PHP should contain this new version of the MySQL connector. I'm gonna try to upgrade the mySQL connector on a 5.2.5 PHP version to see if it fixs the bug [2008-01-03 16:18:34] stalin dot gsk at gmail dot com Include($header) and function fputs($csvf, string) not detecting by PHP 5.2.3 Iam using WIN NT server with IIS 6 Error msg: Warning: include() [function.include]: Failed opening '' for inclusion (include_path='.;./includes;./pear') in C:\Inetpub\vhosts\shopinonline.co.in\cgi-bin\checkout.php on line 61 Iam adding the code below plz check if any thing can be done to make it work advanced thanks for those who can try helping me site was launched and this shopping is making plz help soon. PHP code: checkout.php ? //=|| // NOP Design JavaScript Shopping Cart
#41350 [Com]: Error in my_thread_global_end()
ID: 41350 Comment by: jaco at jump dot co dot za Reported By: graham at directhostinguk dot com Status: No Feedback Bug Type: MySQL related Operating System: Windows 2003 PHP Version: 5.2.3 New Comment: I am having the same and more problems. I am running: Apache 2.2.6 MySQL 5.0.45 PHP 5.2.5 Windows Server 2003 R2 Standard SP2 2 x Quad Core Xeon 4Gb RAM IIS Installed for SMTP, FTP and WWW on port 443 for a single .NET Webservice access (NO PHP connectors installed for IIS). But I am sure this is not IIS related, becuase it still happens even with IIS stopped Whenever apache tries to recycle threads I get: ** Apache Error Log ** [Fri Jan 04 22:37:38 2008] [notice] Child 324: All worker threads have exited. Error in my_thread_global_end(): 1 threads didn't exit exiting because it reached MaxRequestsPerChild. Signaling the parent to restart a new child process. [Fri Jan 04 22:37:42 2008] [notice] Parent: Received restart signal -- Restarting the server. Note the time difference between the first log and the last log This then causes my Apache to crash and restart. Then I tried to download the latest snapshot of PHP, installed it, but then Apache woould not start at all, just gives me a starting status, but does not het out of it. My problem is also that there is hundreds of php files running and our site is very active, and I have NO idea what is causing this problem. The PHP error log is clean, but the following also shows up AFTER apache crashes. 080104 11:24:26 [Warning] Aborted connection 16865 to db: '' user: '*' host: 'localhost' (Got an error reading communication packets) But I am sure that this is just caused by apache that have crashed and the already open calls to the database that was not terminated by the php script. These messages apears in the event log after the crash: Faulting application httpd.exe, version 2.2.6.0, faulting module libapr-1.dll, version 1.2.11.0, fault address 0x79a0. Faulting application httpd.exe, version 2.2.6.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xacb9. We are using both mysql and mysqli connectors and I have tried to download the ones from the mysql site and again apache refused to start. This is quite serious for us at the moment, becuase its in a live enviroment and the dev servers never had this problem. Hope we can find a solution soon. Previous Comments: [2008-01-04 18:28:12] jcmelcher at gmail dot com This worked for me... IIS 6.0 with PHP 5.2.5 on Win2K3 SP2 If you download the latest PHP - MySQL connector files direct from MySQL this problem goes away:- http://dev.mysql.com/downloads/connector/php/ [2008-01-04 14:30:55] benjamin dot azan at gmail dot com I could not find the new version of mysql connector but I changed the PHP mode from CGI/fastCGI to Apache 2.0 Handler and it fixed the problem. [2008-01-04 11:54:05] benjamin dot azan at gmail dot com The mySQL bug http://bugs.mysql.com/bug.php?id=25621 says : MySQL 5.0.54BK on WinXP localhost does not exhibit the error. and the PHP 5.2.5 show Client API version 5.0.45 So I think the next version of PHP should contain this new version of the MySQL connector. I'm gonna try to upgrade the mySQL connector on a 5.2.5 PHP version to see if it fixs the bug [2008-01-03 16:18:34] stalin dot gsk at gmail dot com Include($header) and function fputs($csvf, string) not detecting by PHP 5.2.3 Iam using WIN NT server with IIS 6 Error msg: Warning: include() [function.include]: Failed opening '' for inclusion (include_path='.;./includes;./pear') in C:\Inetpub\vhosts\shopinonline.co.in\cgi-bin\checkout.php on line 61 Iam adding the code below plz check if any thing can be done to make it work advanced thanks for those who can try helping me site was launched and this shopping is making plz help soon. PHP code: checkout.php ? //=|| // NOP Design JavaScript Shopping Cart || // PHP SCRIPT Checkout Module || // || // For more information on SmartSystems, or how NOPDesign can help you || // Please visit us on the WWW at http://www.nopdesign.com || // || // Javascript portions of this shopping cart software are available as || // freeware from NOP Design. You must keep this comment unchanged in || // your code. For more information contact [EMAIL PROTECTED
#39221 [Com]: php5ts.dll faulting every few minutes on apache2.2
ID: 39221 Comment by: jaco at jump dot co dot za Reported By: kris at k-software dot org Status: No Feedback Bug Type: Apache2 related Operating System: windows server 2003 x64 PHP Version: 5CVS-2006-10-20 (snap) New Comment: I am also having this problem on our production machine Apache 2.2.6 PHP 5.2.5 MySQL 5.0.45 Windows Server 2003 R2 Standard SP2 2 x Quad Core Zeon Error in Eventlog Faulting application httpd.exe, version 2.2.6.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0xacb9. Our production server is quite busy, and we have hundreds of PHP pages and I am unable to trace this to a specific php file. I would love to try the solution of giving httpd.exe access to a single processor. Could someone please let me know how I can set that up Thanks and hope we can find a solution soon Previous Comments: [2007-04-20 16:48:33] niels at keurentjes dot net I'm still having the problems, albeit less frequently after some performance tuning, but still too often. In my case, it's mainly some Ajax pages, inherently causing a lot of pageviews, that trigger the problem. I'm not in a position to run snapshots on the involved production machines, but I'm highly curious whether the problem was really attacked and or fixed now. [2007-03-27 16:23:53] php at blazemonger dot com The problem appears to be gone in today's latest snapshot of PHP 5.2. I hammered MediaWiki for 15-20 minutes and didn't see a single error. [2007-03-27 13:46:52] php at blazemonger dot com Following up my previous comment: this is easily reproduced if I set up 3-4 scripts to simultaneously pound MediaWiki with requests to the Special:Random page, e.g., # repeat 1000 times wget -O - http://servername/wiki/Special:Random I have reproduced this on both the 32-bit and 64-bit versions of Windows 2003 Server SP1, with the software versions given earlier. [2007-03-25 03:02:40] php at blazemonger dot com I can reproduce this PHP crash easily in our MediaWiki 1.9.3 installation. Visit the main page and click the Random page link (in the left navigation menu) repeatedly, as fast as you can, about 50 times. The error is thrown into the event log: Faulting application httpd.exe, version 2.2.4.0, faulting module php5ts.dll, version 5.2.1.1, fault address 0xae66. and Apache becomes completely unresponsive (will not respond to any page requests) and must be restarted. Windows 2003 Server SP1 64-bit (2 GB RAM) Dual core AMD Opteron (2.81 GHz, Processor 8220 SE) Apache 2.2.4 with SSL PHP 5.2.1 (apache2handler) MediaWiki 1.9.3 MySQL 5.0.27-community-nt This is a VMware virtual machine if that matters. [2007-02-16 11:01:41] niels at keurentjes dot net I have the exact same issue: a stock Win2k3 setup with Apache 2.2.4 and PHP 5.2.1 on a Dual Xeon HT setup, and regular crashes, several times per day, sometimes 15 in 30 minutes when the site is being hit severely. I have performed several recent software upgrades, the problems also occurred in the exact same fasion in Apache 2.0.59 + PHP 5.1.4, Apache 2.0.59 + PHP 5.2.0 and Apache 2.2.4 + PHP 5.2.1. I am currently testing whether hard-forcing uniprocessor operation using ImageCfg (http://www.robpol86.com/Pages/imagecfg.php) works. I have set the httpd.exe process to the following: --- httpd.exe contains the following configuration information: Process Affinity Mask: 0001 httpd.exe contains a Subsystem Version of 4.0 Image can only run in uni-processor mode on multi-processor systems --- Notably the crashes seemed to become less frequent when I disabled all caching on the site. At first I suspected this pointed towards problems with too many files open simultaneously, but I am now after reading these problems pretty sure that it merely slowed down the site enough not to trigger the synchronization issues or race conditions. 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 http://bugs.php.net/39221 -- Edit this bug report at http://bugs.php.net/?id=39221edit=1