PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: May 21, 2012 06:29AM

Hi, I have an installation of a php application(SugarCRM) which is running fine in Mac OS X, but when I run the same code in WAMP, it crashes Apache. The following error message is in the apache_error.log

Parent: child process exited with status 255 -- Restarting

And in the Windows Event log, I can see that httpd process has crashed, with the faulting module = c:\wamp\bin\apache\apache2.2.21\bin\php5ts.dll

Has anyone else seen this?

This was happening with wamp server 2.1, so this morning I updated everything to 2.2 and still have the same problem.

I'm running Windows 7x64 bit and WAMP 2.2 64-bit.

Other PHP applications and test files work fine, it's just this particular application. I'm certain it's not a problem in php code because it works perfectly on mac with built in apache and php 5.3.10.

Any ideas?

Edit: The crash happens in 32-bit installation as well as 64-bit.

A colleague running Windows 7x32 works fine with exactly the same php code.



Edited 1 time(s). Last edit at 05/21/2012 06:36AM by mattconnolly.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: stevenmartin99 (Moderator)
Date: May 21, 2012 09:09AM

There must be Something in te php error log??

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: May 21, 2012 09:29AM

The only line of any significance in the error log, I already quoted:


Parent: child process exited with status 255 -- Restarting


You can see a full log of trying to access the site several times in this pastie: [pastie.org]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: stevenmartin99 (Moderator)
Date: May 21, 2012 10:45AM

That's not the php log

That's the apache log

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: May 22, 2012 01:17AM

The php error log is completely blank.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: May 22, 2012 01:48AM

The app I'm running is SugarCRM. Exactly the same source code runs fine on Mac and on a colleague's WAMP installation on Win 7x32 bit.

I attached the php debugger with netbeans and stepped through the application. It crashes when requiring a file ('/includes/MVC/SugarApplication.php' if it makes any difference)

If I go into the file and add a comment near the beginning, like

// hello

Then php runs fine. If I remove the comment, php crashes apache with no error message in the php error log, and only "child exited 255" in the apache error log.

The total lack of error messages is what I find most frustrating about this scenario. But let this be a tip to others who encounter the same problem: use a debugger to find where php is crashing and fiddle.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: stevenmartin99 (Moderator)
Date: May 22, 2012 01:58AM

Are u really saying that adding sonething that the php parser ignores , changes the outcome?

U will need to look at the last lines of code that are run before
That file is included then.

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: May 22, 2012 03:25AM

That's exactly what I'm saying.

The line before is:

require_once('includes/MVC/SugarApplication.php');

with the comment NOT there, php crashes when requiring that file - the debugger does not step into the file like it does with other require/includes.

with the comment ADDED, php passes that file and executes normally.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: stevenmartin99 (Moderator)
Date: May 22, 2012 06:15AM

Can you mail me that application file?

Your adding the comment into that file yes?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: jvargas (201.191.123.---)
Date: May 25, 2012 08:54AM

I got the same problem, but with a particular Joomla! site.

I run the same site with no changes at all and it works very well.

The php5ts.dll is crashing.

I tried to debug and determine the cause, but it happens when the main Joomla! index.php calls $mainframe->dispatch(), used by Joomla! to start processing and rendering the site.

It never enters the method body, it just fails by when calling it.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: khron (---.dia.static.qwest.net)
Date: June 21, 2012 01:27AM

I've been getting this same exact problem on my Drupal 7.8 install, but ONLY when I've logged in as an admin user and this happens whenever I try to pull up a "admin/" page.

So frustrating!

I have tried numerous versions of WampServer on this Windows Server 2008 R2 Standard box, and nothing seems to take.

Just venting my thoughts here, and I'll respond with any headway!

-Ken

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: mattconnolly (175.176.203.---)
Date: June 22, 2012 02:03AM

I've come across this bug again.

The attached pastie has a file that is unchanged from SugarCRM 6.4 and is crashing my Wamp Apache in php5ts.dll.

The file can be seen here: [pastie.org]

There are no PHP errors in the file. It works fine on my colleague's Win32 machine, and on Mac apache. Adding a comment like this to the top of the file makes it work again:

/* please don't crash */

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: khron (---.dia.static.qwest.net)
Date: September 13, 2012 10:56PM

Not really a solution, but I tried the exact same site using XAMPP and it works perfectly.

Go figure.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: stevenmartin99 (Moderator)
Date: September 13, 2012 11:02PM

you all must using 64bit wamp , i guess

try 32bit

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: sokrplare (---.mdp.com)
Date: February 26, 2014 08:16PM

Not exactly the answer I hoped for, so tried everything else, but after two days finally had to relinquish, uninstall WAMP 64-bit, and then install 32-bit and it fixed it.

Ugh.

Options: ReplyQuote
Re: PHP crashing Apache
Posted by: RiggsFolly (---.as13285.net)
Date: February 26, 2014 09:55PM

The 32bit version is safer for many reasons.

64bit PHP still carries a comment of "EXPERIMENTAL" [windows.php.net] see section on left column labeled x86_64 Builds

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote


Sorry, only registered users may post in this forum.