Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 27852

Long running php/fastcgi script hangs on IIS 7.5

$
0
0

I have a php application running on IIS 7.5 , php 5.4 running as fastcgi. The application works absolutley fine with the exception that long running php scripts seem to hang; no 500 error they simply seem never complete and return the results to the browser.

I've written a simple test script below to eliminate the possibility of programming error in the main app :

<?php echo "Testing time out in seconds\n";  for ($i = 0; $i < 175; $i++) {  echo $i." -- "; if(sleep(1)!=0) {  echo "sleep failed script terminating";  break;  } } ?>

If I run the script beyond 175 seconds it hangs. Below that it will return the results to the browser.

Here are the time out parameters that I've set for php and fastcgi. I've also played around setting these really low in order to get various time out errors and have succeeded which brings me to the conclusion that there's another setting that I'm missing .. perhaps.

Correct me if my presumptions are wrong but would it be fair to say that if a script times out the browser will get an error where as if a script is killed off by IIS before completion then nothing is returned to the browser and you get a what looks like a hang as far as the browser is concerned?

fastcgi

activity timeout=800IdleTimeout=900 request Timeout800

Php

max_execution_time=700


Viewing all articles
Browse latest Browse all 27852

Trending Articles