Jump to content

A crash and no errors


chrisrusso

Recommended Posts

Hi, I'm Chris, first time here, I usually post on stackoverflow but I think that this is a little bit more complex than usual.

I believe I really need a PHP expert to solve this issue. We have an application which is crawling the web. There's 2 main PHP scripts that are doing the work, using using proc_open, and exec() and running over a circular reference. Both scripts that compose the main structure are saving all and every single error on a custom error log, defined this way:

//error_log
@ini_set('error_reporting', -1);
@ini_set('log_errors','On');
@ini_set('display_errors','On');
@ini_set('error_log','/var/www/vhosts/xxx/xxx/resonance/such_a_mess');

The problem is simple, after running for some hours or days, the application stops crawling. And there's no error information at all on the error_logs that could explain the problem or the reason why it stopped. I've been trying to get more details using Newrelic and XHProf, no luck.-

There's no HTTP server involved on the execution of the scripts as they are being executed like I mentioned, using exec() and proc_open:

exec("sh -c \"$cmd | logger\" > /dev/null &");

It has been around 3 months on the same situation... and to be honest the only thing I want at this point is to see a fatal error on the logs, to understand what's going on...

Link to comment
Share on other sites

Why do you have display errors on?  Won't that display to your console as well as your log?

 

Why do you have @ in front of those commands?  You don't want to know about any error that may occur?

 

Are you sure your script has access to the desired error log location?  Is there in fact a log file to view?

 

How about logging your progress as your script proceeds?  Maybe it's a particular site that is killing your script somehow.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.