• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 182
  • Last Modified:

PHP on Windows - how to log when a script is timing out

I have a php application that I did not write that is running on my server (IIS on Windows 2003 Server).  I suspect that I am having a php timeout issue, but am not sure.  Is there a way to know for certain that a timeout is occurring?  Can this be written to the log file?  If so, how?

I just need some clear confirmation that what I am seeing is a php timeout.
0
sah18
Asked:
sah18
1 Solution
 
Dave BaldwinFixer of ProblemsCommented:
I suggest you click on "Request Attention" and get the IIS web server zones added.  The timeout message may or may not tell you what timed out.  The IIS log should.
0
 
themrrobertCommented:
If you find the php installation directory, look in the directory for error.log  update this log file.

This log file is very detailed on showing php errors and should help get you on track
0
 
Sandeep KothariProject LeadCommented:
check for register_shutdown_function

http://php.net/manual/en/function.register-shutdown-function.php

write a shutdown function to log all the errors and warnings....  like this. .. .
register_shutdown_function('logErr');
function logErr(){
$path_to_logfile = "/tmp";
error_log("<br>".print_r(error_get_last(),true),3,$path_to_logfile);
}

Open in new window


hope it helps
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now