You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2013/10/24 12:12:14 UTC

[Bug 55698] New: Apache 2.2 + mod_fcgid 2.3.7 (CentOS 6.4) graceful restarts, no leftover processes, but errors both in browser and error log

https://issues.apache.org/bugzilla/show_bug.cgi?id=55698

            Bug ID: 55698
           Summary: Apache 2.2 + mod_fcgid 2.3.7 (CentOS 6.4) graceful
                    restarts, no leftover processes, but errors both in
                    browser and error log
           Product: Apache httpd-2
           Version: 2.2-HEAD
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: major
          Priority: P2
         Component: mod_fcgid
          Assignee: bugs@httpd.apache.org
          Reporter: georgi.petrov@seocreativebrain.com

Upon graceful restart the CGI processes get forcefully killed before they end
and you don't get the output to the browser.

What is the setup:

CentOS 6.4 x86_64 minimal installation
mod_fcgid.x86_64 2.3.7-1.el6 
httpd.x86_64 1:2.2.15-29.el6.vm.1
php.x86_64 5.3.3-23.el6_4

Single virtual domain, running under mod_fcgid execution mode, with 90 sec PHP
execution time and fcgid IO wait.

Single test.php file containing (just sleep loop):

<?php
for($i = 1; $i <= 30; $i++) {
    echo $i."\n";
    sleep(1);
    file_put_contents("test.txt", "test run for: ".$i." seconds");
}
?>

What is the error:

Run the script via browser, then go and do a graceful restart on Apache
(service httpd graceful). After around 12 seconds you are going to see "No data
received" error in you browser (Chrome) and the following in the Apache error
log:

(22)Invalid argument: mod_fcgid: can't lock process table in pid [some_pid]

Examining test.txt shows that this script gets forcefully killed before ending.

If you reduce the time the script executes to 5 seconds ($i <= 4), you'll get
the same result, this time after 5 seconds.

Examining test.txt shows this process completes, but you still get the errors
both in the browser and the error log.

So why 12 seconds and where is this set. After some time I discovered that
increasing FcgidErrorScanInterval to 60 will let the process with 30 sec loop
to complete (but still you get the errors).

The error in the log "can't lock process table in pid..." probably means that
some information about the process is destroyed immediately upon the graceful
restart (I assume it is something with the mutex).

Even if we get around the early termination of the processes increasing
FcgidErrorScanInterval the second problem is actually bigger - the script
output never gets back.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 55698] Apache 2.2 + mod_fcgid 2.3.7 (CentOS 6.4) graceful restarts, no leftover processes, but errors both in browser and error log

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=55698

--- Comment #1 from Thomas Gross <to...@webdrive.co.nz> ---
Has there been any progress on this?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org