View Issue Details

IDProjectCategoryView StatusLast Update
0000299Apache 2.x Bugpublic2020-08-24 03:12
Reporterssha Assigned Topsmedley  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionduplicate 
Product Versionv2.2.1 
Summary0000299: Apache + PHP5 crashes regularly under light load
DescriptionWhen using Apache and PHP5 to run Jinzora, Apache sometimes (and quite regularly) crashes. I have not been able to reproduce an exact request or event that will cause Apache to crash - sometimes it will crash in the night all of its own accord.

The most frequent message is:

[Thu Dec 04 13:21:33 2008] [error] caught exception (XCPT_ACCESS_VIOLATION) in worker thread, initiating child shutdown pid=175
[Wed Dec 10 22:25:29 2008] [error] caught exception in worker thread, initiating child shutdown pid=342
apr_canonical_error: Unknown OS/2 error code 10004
[Wed Dec 10 22:42:41 2008] [error] (OS 10004)Unknown error -1: apr_socket_accept
[Wed Dec 10 22:42:41 2008] [error] (OS 10004)Unknown error -1: apr_socket_accept
[Wed Dec 10 22:42:41 2008] [error] (OS 10004)Unknown error -1: apr_socket_accept
[Wed Dec 10 22:42:41 2008] [notice] caught SIGTERM, shutting down

(The events at 22:42:41 are caused by my CTRL-C the dead Apache window to close it).

Sometimes tho an exception is raised in PHP:

Killed by SIGSEGV
pid=0x00af ppid=0x00ad tid=0x0001 slot=0x00b6 pri=0x0200 mc=0x0001
C:\APACHE2\BIN\HTTPD.EXE
PHP5 0:001ef9b1
cs:eip=005b:1d57f9b1 ss:esp=0053:0012fe20 ebp=0012fe48
 ds=0053 es=0053 fs=150b gs=0000 efl=00210246
eax=00000000 ebx=00504368 ecx=00000000 edx=00000000 edi=00000000 esi=00000000
Process dumping was disabled, use DUMPPROC / PROCDUMP to enable it.

Still other times an entry is logged into POPULOG.OS2 (popuplog entries are not raised for the XCPT_ACCESS_VIOLATION error):

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

12-10-2008 21:07:34 SYS3175 PID 0149 TID 0003 Slot 00c8
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1ffd0844
P1=00000008 P2=00000258 P3=XXXXXXXX P4=XXXXXXXX
EAX=00000000 EBX=0056126a ECX=02590149 EDX=17329827
ESI=0259ffa7 EDI=0259fee0
DS=9807 DSACC=00f3 DSLIM=0000117f
ES=980f ESACC=00f3 ESLIM=00001e5d
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=ffef:00000844 CSACC=00df CSLIM=0000fdf8
SS:ESP=12cf:0000fe04 SSACC=00f3 SSLIM=0000ffff
EBP=02590000 FLG=00010246

DOSCALL1.DLL 0003:00000844

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

12-10-2008 23:16:33 SYS3171 PID 023c TID 0003 Slot 00ca
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1d6196bf
P1=00000002 P2=0257fffc P3=XXXXXXXX P4=XXXXXXXX
EAX=02580020 EBX=02585a68 ECX=00000000 EDX=00000008
ESI=00763160 EDI=007a67a0
DS=0053 DSACC=f0f3 DSLIM=ffffffff
ES=0053 ESACC=f0f3 ESLIM=ffffffff
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=005b:1d6196bf CSACC=f0df CSLIM=ffffffff
SS:ESP=0053:0257fffc SSACC=f0f3 SSLIM=ffffffff
EBP=025806b4 FLG=00010202

PHP5.DLL 0001:002896bf


Remote access to this system can be arranged, if required.

Because of the regularity of this problem, I suspect that there is some kind of generic fault with Apache - certainly the XCPT_ACCESS_VIOLATION when the system is not busy at all seems very strange). I am also working on the premise that no code error in the Jinzora PHP code should be able to cause this - I can't find others having this problem, at any rate.
Additional InformationTo reproduce this problem with Jinzora:

1. Install Paul's PHP/MySQL/Apache
2. Download Jinzora 2.7.5 stable and unzip to c:/jinzora2
3. Set an alias in httpd.conf for Jinzora2
4. Setup Jinzora and import a little media (not much is required)
5. Use Jinzora

A crash will soon happen :(

Hope this you can help!
TagsNo tags attached.

Relationships

duplicate of 0000425 closedpsmedley Unknown crashes with Apache 2.2.11 

Activities

ssha

2009-01-01 15:22

reporter   ~0001087

Hi Paul,

Hope you are OK.

Still happens with latest Apache + PHP (2.2.11 + 5.2.8)

Also now see the following error:

LIBC PANIC!!
fmutex deadlock: Owner died!
0x0050013c: Owner=0x814e0009 Self=0x814e0001 fs=0x3 flags=0x0 hev=0x0001004f
            Desc="LIBC Heap"
pid=0x814e ppid=0x814c tid=0x0001 slot=0x00f8 pri=0x0200 mc=0x0000
C:\APACHE2\BIN\HTTPD.EXE
Process dumping was disabled, use DUMPPROC / PROCDUMP to enable it.

As this clearly shows HTTPD having at least one problem (whether or not it is the same as above), would you like me to open a seperate bug report for Apache?

The above error happens when you ask a big PHP task - e.g. a re-scan of media under Jinzora.

Thanks,
Stephen

psmedley

2009-01-02 07:17

administrator   ~0001092

I will try and setup Jinzora here - no need for a separate ticket - it's all related to Jinzora :)

ssha

2009-01-04 14:47

reporter   ~0001093

Hi Paul,

Thanks :)

Am using Jinzora 2.75 - JZ275.zip from the website.

Remote access to my NAS/Media box is available, if you want - via VNC.
PM me to steve@stevesharrad.co.uk if you need access.

Thanks again,
Stephen

psmedley

2009-02-05 09:42

administrator   ~0001110

http://smedley.info/httpd.zip tidies up a few things and _may_ help

psmedley

2009-02-22 09:18

administrator   ~0001149

http://smedley.info/php5.zip tidies up a few PHP related issues and _may_ also help

ssha

2009-02-27 23:43

reporter   ~0001221

Still fails now and then, even with both updates:

02-27-2009 21:41:28 SYS3171 PID a40c TID 0008 Slot 00a3
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1d66df5c
P1=00000002 P2=0262ffd4 P3=XXXXXXXX P4=XXXXXXXX
EAX=02a347e8 EBX=00000014 ECX=00d0c240 EDX=00a66ca0
ESI=009d2048 EDI=02630698
DS=0053 DSACC=f0f3 DSLIM=ffffffff
ES=0053 ESACC=f0f3 ESLIM=ffffffff
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=005b:1d66df5c CSACC=f0df CSLIM=ffffffff
SS:ESP=0053:0262ff9c SSACC=f0f3 SSLIM=ffffffff
EBP=02630024 FLG=00010216

PHP5.DLL 0001:0031df5c

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

02-27-2009 21:41:52 SYS3171 PID 8ec9 TID 0008 Slot 0100
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1d66df5c
P1=00000002 P2=0262ffd4 P3=XXXXXXXX P4=XXXXXXXX
EAX=01309c80 EBX=00000014 ECX=01a2b2a0 EDX=00fa9d20
ESI=00cc3dd8 EDI=02630698
DS=0053 DSACC=f0f3 DSLIM=ffffffff
ES=0053 ESACC=f0f3 ESLIM=ffffffff
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=005b:1d66df5c CSACC=f0df CSLIM=ffffffff
SS:ESP=0053:0262ff9c SSACC=f0f3 SSLIM=ffffffff
EBP=02630024 FLG=00010216

PHP5.DLL 0001:0031df5c

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

02-27-2009 22:52:58 SYS3175 PID c3c7 TID 0003 Slot 0124
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1ffd0844
P1=00000008 P2=00000164 P3=XXXXXXXX P4=XXXXXXXX
EAX=00000000 EBX=1ffca330 ECX=0259fef4 EDX=17349827
ESI=0259fef4 EDI=00000000
DS=0053 DSACC=f0f3 DSLIM=ffffffff
ES=0053 ESACC=f0f3 ESLIM=ffffffff
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=005b:1ffc9f77 CSACC=f0df CSLIM=ffffffff
SS:ESP=0053:0259fb34 SSACC=f0f3 SSLIM=ffffffff
EBP=0259fb7c FLG=00000246

DOSCALL1.DLL 0003:00000844


Apache error log shows:

[Fri Feb 27 22:51:07 2009] [error] caught exception (XCPT_ACCESS_VIOLATION) in worker thread, initiating child shutdown pid=50119
[Fri Feb 27 22:51:07 2009] [error] caught exception in worker thread, initiating child shutdown pid=50119
[Fri Feb 27 22:53:08 2009] [notice] caught SIGTERM, shutting down

With this failure, the Apache process is still running - but not serving anything :(

ssha

2009-03-14 14:57

reporter   ~0001249

And again...

Apache seems to become exhausted, i.e. causing a Jinzora re-scan causes thousands of requests as each album is shown in the scan window...

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

03-13-2009 22:37:38 SYS3175 PID 501a TID 0004 Slot 0115
C:\APACHE2\BIN\HTTPD.EXE
c0000005
1ffd0844
P1=00000008 P2=00000164 P3=XXXXXXXX P4=XXXXXXXX
EAX=00000000 EBX=1ffca330 ECX=025bfef4 EDX=17349827
ESI=025bfef4 EDI=00000000
DS=0053 DSACC=f0f3 DSLIM=ffffffff
ES=0053 ESACC=f0f3 ESLIM=ffffffff
FS=150b FSACC=00f3 FSLIM=00000030
GS=0000 GSACC=**** GSLIM=********
CS:EIP=005b:1ffc9f77 CSACC=f0df CSLIM=ffffffff
SS:ESP=0053:025bfb34 SSACC=f0f3 SSLIM=ffffffff
EBP=025bfb7c FLG=00000246

DOSCALL1.DLL 0003:00000844

psmedley

2009-03-14 22:31

administrator   ~0001255

You could try increasing the number of file handles available for each process.

SET SHELLHANDLESINC=50
then start httpd

David McKenna

2009-03-15 01:16

reporter   ~0001256

Look for multiple copies of php5.dll on your drive(s). Make sure Apache is loading the one that matches modphp5.dll.

psmedley

2009-07-30 21:48

administrator   ~0001383

I'm curious if http://smedley.info/httpd-2.2.11-os2-20090728.zip helps in any way

ssha

2009-08-08 15:49

reporter   ~0001390

See bug 0000355 for some feedback on testing - a bit better, but memory usage seems to be the key.

psmedley

2010-07-11 03:12

administrator   ~0001638

Please try http://download.smedley.info/httpd-2.2.15-os2-20100711.zip

jimoe

2010-08-12 07:35

reporter   ~0001702

httpd 2.2.16, mysql 5.1.49, php 5.2.14

I have a similar problem. I suspect the actual culprit is mysql.

I finally updated AMP last week. All seemed to be well until I attempted to connect to a remote mysql database, i.e., not one on the localhost. Then httpd quietly quits. No messages, nothing in the logs, poof!.

It's pretty reliable about quitting. Although I did have it stop once while accessing a localhost database, but after restart it worked so it's a bit erratic for the localhost.

Issue History

Date Modified Username Field Change
2008-12-11 00:30 ssha New Issue
2008-12-12 03:28 psmedley Status new => assigned
2008-12-12 03:28 psmedley Assigned To => psmedley
2009-01-01 15:22 ssha Note Added: 0001087
2009-01-02 07:17 psmedley Note Added: 0001092
2009-01-04 14:47 ssha Note Added: 0001093
2009-02-05 09:42 psmedley Note Added: 0001110
2009-02-22 09:18 psmedley Note Added: 0001149
2009-02-22 09:18 psmedley Status assigned => feedback
2009-02-27 23:43 ssha Note Added: 0001221
2009-03-14 14:57 ssha Note Added: 0001249
2009-03-14 22:31 psmedley Note Added: 0001255
2009-03-15 01:16 David McKenna Note Added: 0001256
2009-07-30 21:48 psmedley Note Added: 0001383
2009-08-08 15:49 ssha Note Added: 0001390
2010-07-11 03:12 psmedley Note Added: 0001638
2010-08-12 07:35 jimoe Note Added: 0001702
2011-12-31 08:27 psmedley Relationship added duplicate of 0000425
2011-12-31 08:27 psmedley Status feedback => resolved
2011-12-31 08:27 psmedley Resolution open => duplicate
2020-08-24 03:12 psmedley Status resolved => closed