httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Digvijoy Chatterjee <digvijo...@gmail.com>
Subject [users@httpd] apache problems with blocking cgi requests
Date Sat, 25 Jul 2009 14:47:18 GMT
Hi,

We are running apache 2.0.35 on RHEL4 running in prefork mode.
Its a standard apache configuration for running cgi scripts. I can
send it if required

The behaviour we are observing with apache is after servicing 2 cgi
requests which are blocking (do a long database lookup ~5 minutes)
apache will not service any other cgi requests until one of the above come back.

I have been able to simplify our problem as below.
Just put test.cgi and sleep.cgi in your cgi path and launch test.cgi in apache.

test.cgi just presents a link to sleep.cgi which sleeps for 60 seconds.
No matter how many times I launch this link in a new tab/windown in a browser

when I do a

ps -ef | grep sleep.cgi

on the webserver box, I just see one process! and later when this
finishes its still just one perl process running sleep.cgi ( a
different pid )

Apache has atleast 5 children waiting on accept()
but despite  launching multiple tabs in the browser,
it is not handling the new cgi requests to these idle child processes.

Is it an apache config setting/something in mod_cgi , appreicate any help.

Scripts for perusal below

== Test.cgi==
print "ContentTyep: text/html\n\n";
pringt << EOF
<html>
<br>
<a href="http://localhost/cgi-bin/reports/sleep.cgi>Launch the sleep CGI<\a>
<br>
<html>
EOF
==

== Sleep.cgi ==
sleep(60);
==

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message