ID: 36895 Comment by: karlsonas at mazylis dot lt Reported By: jsschuetz at knapheide dot com Status: No Feedback Bug Type: ODBC related Operating System: server2003/WinXP Pro PHP Version: 5.1.2 New Comment:
Hi, I've tryed several combinations of Apache/PHP and found only one which still generated error, but Apache recovers from crach and continues to work. It's PHP 5.1.1/Apache 2.0.55 Combinations on which Apache crashes without recovering: PHP5.1.4/Apache2.0.58 PHP5.1.6/Apache2.0.59 PHP5.1.1/Apache2.0.59 PHP5.1.6/Apache2.0.55 I have two servers - test and production with exact configuration and code. And strangest thing that I have PHP5.1.4/Apache2.0.58 working without any problems on test server and can't get it crash at all. On production server I have crach after 15-30mins after upgrade. Of course production server is used by 100-200 users... I've tryed to look through acceess/error logs but really can't find what is cousing this crash ... Could You please give me a way to debug that not rising production servers resources use ? I will try to follow instructions on back-trace .. but it's kind a hard on prod server :) Wish me luch :) Previous Comments: ------------------------------------------------------------------------ [2006-08-02 10:50:04] matthius at pointbtel dot com I'm fairly certain that I am suffering from this same bug. Though I am not using ODBC, I do however hit MySQL pretty hard. Sadly I'm not equipped to generate a backtrace on this machine. This is a major problem though, I am going to have to roll everything back to PHP4 bacause i can't seem to keep Apache on its feet for more than 15 min as it is. I'm currently running PHP 5.1.4 and I've tried Apache 2.0.53 and 2.2.3. - both die the same way :-( - Matt ------------------------------------------------------------------------ [2006-04-20 01:00:01] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open". ------------------------------------------------------------------------ [2006-04-12 14:59:28] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a backtrace to see what is happening behind the scenes. To find out how to generate a backtrace, please read http://bugs.php.net/bugs-generating-backtrace.php for *NIX and http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32 Once you have generated a backtrace, please submit it to this bug report and change the status back to "Open". Thank you for helping us make PHP better. ------------------------------------------------------------------------ [2006-04-12 13:30:47] jsschuetz at knapheide dot com I narrowed down the code causing the problem. The below is the entire program that will cause the error at random. I am connecting to a DB2 database on an AS400 Iseries with ODCB drivers provided by IBM client access software. --------------------------------------------------------- $con = odbc_connect('as400','username','password'); ?> <META HTTP-EQUIV="Refresh" CONTENT="2;URL=nester.php"> <BR /> Version 6 <br /> <? $SSnestfiles = "Select * from pdatalib.nestsumpf where nesalpha = 'D' order by NESDTE DESC, NESTIME DESC"; $SRnestfiles = odbc_exec($con,$SSnestfiles); while($nestfilearray = odbc_fetch_array($SRnestfiles)) { } The issue occurs with the odbc_fetch array call. If the "while($nestfilearray = odbc_fetch_array($SRnestfiles))" is commented out the code will run fine forever, with the statement in, there will be random crashes as described previously. The Meta refresh is simply there to keep executing the code because the error occurs at random. In a test environment I opened 6 instances of the program and allowed them to sit refreshing every 2 secs. The error would occur every 2 to 20 mins. With IIS, it would crash and need to be restarted with a PHP Access Violation, with Apache there would just be an event log and the Apache service would restart. ------------------------------------------------------------------------ [2006-03-28 17:22:24] jsschuetz at knapheide dot com Description: ------------ IIS and/or Apache on Server 2003 faulting application error and PHP has encountered an Access Violation at 000224b2 When running IIS with PHP 5.1.2.2 I get random crashes with the message PHP has encountered an Access Violation at 000224b2 and an error message in event viewer throws the message: Faulting application w3wp.exe, version 6.0.3790.1830, faulting module ntdll.dll, version 5.2.3790.1830, fault address 0x000224b2. I tried reinstalling IIS and PHP with no luck. To tried to fix the problem by installing Apache 2.0.55 instead thinking it might be an IIS problem. Now I don't see the Access Violation message, but I still get messages in event viewer that saying: Faulting application Apache.exe, version 2.0.55.0, faulting module ntdll.dll, version 5.2.3790.1830, fault address 0x000224b2. and Faulting application Apache.exe, version 2.0.55.0, faulting module cwbrw.dll, version 0.0.0.0, fault address 0x00007fbd. Reproduce code: --------------- I have not been able to isolate specific code that is causing this problem. The error seems to come at random and this is on a production server running many PHP apps. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=36895&edit=1