Hi,
I have a PHP script which is time consuming (1 min.). Under IIS, if I execute the script via HTTP, it gets all resources and you cannot execute any other script until the "heavy" script has finished. The other scripts go to a kind of "queue" and start only when the first one has finished.
However, under Apache on Linux systems, this does not happen. You can connect to different PHP pages while the heavy script is still running and you won't even notice.
Is there something wrong in my configuration of IIS which does not allow concurrent PHP scripts, or is it normal because of it being a Windows system?
Thanks!!!
Concurrent PHP scripts in IIS - 1 script getting * resources
Moderator: General Moderators
Concurrent PHP scripts in IIS - 1 script getting * resources
Last edited by cesar2005 on Thu Mar 03, 2005 5:03 am, edited 1 time in total.
Yes, I completely agree, but I may need to run PHP on IIS as a web service, and still not very sure if it can be done, at least with concurrent users and long running scripts.
It seems that Apache handles multiple requests as different processes, while ISS handles multiple requests in a single process, but with multiple threading. Does this mean that there is no solution for my problem, i.e., am I forced to use Apache instead of IIS? Then why the Windows PHP installation at all? It does not make sense to me...
It seems that Apache handles multiple requests as different processes, while ISS handles multiple requests in a single process, but with multiple threading. Does this mean that there is no solution for my problem, i.e., am I forced to use Apache instead of IIS? Then why the Windows PHP installation at all? It does not make sense to me...
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
From what I remember, IIS is not multithreaded.. or the ISAPI modules aren't thread safe (this may be an issue with the php module itself, I don't know).. or something like that. This "heavy" script should be done outside a http environment if possible.
There are also things of processing demand. If a thread/process needs more time it can ask for it, or receive it automatically. This may also be apart of the module code, and not all modules or the server itself.
The actual scheduling system is very similar between Windows and Linux.
There are also things of processing demand. If a thread/process needs more time it can ask for it, or receive it automatically. This may also be apart of the module code, and not all modules or the server itself.
The actual scheduling system is very similar between Windows and Linux.
Oh, I forgot to tell that I am running PHP as ISAPI. I haven't tested as CGI yet, maybe would be the solution, even if it is told to run slower.
I will test tomorrow. The problem is that I am generating some reports on the fly, and that is time consuming, and wouldn't like to have the other clients waiting for the script to finish. As I said, this script is completely unnoticeable in the performance of other users if I use Apache.
I will test tomorrow. The problem is that I am generating some reports on the fly, and that is time consuming, and wouldn't like to have the other clients waiting for the script to finish. As I said, this script is completely unnoticeable in the performance of other users if I use Apache.