Pantek Library
Hosting Provided By
CybrHost
High Speed Hosting

DO NOT REPLY [Bug 7572] New: - mod_proxy does not reset timer when reading from client

From: <bugzilla(at)apache.org>
Date: Thu Mar 28 2002 - 07:21:47 EST


DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7572>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7572

mod_proxy does not reset timer when reading from client

           Summary: mod_proxy does not reset timer when reading from client
           Product: Apache httpd-1.3
           Version: 1.3.24
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: Critical
          Priority: Other
         Component: mod_proxy
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: brian.bothwell@wisdomtools.com

This bug was submitted by Martin Lichtin <martin@lichtin.net> to the old Apache bug system back in May 2000:

http://bugs.apache.org/index.cgi/full/6127

I discovered this issue when trying to upload large files over slow connections to our web application, which uses a light front-end mod_proxy server to pass requests to many heavy mod_perl server. We were getting the following error on the mod_perl backend servers:

CGI.pm: Server closed socket during multipart read (client aborted?). [Tue Mar 26 16:44:59 2002] [error] [client 63.74.45.131] Premature end of script headers: /www/cgi-bin/test.cgi

Turned out the uploads would fail after 300 seconds, the "Timeout" value on the mod_proxy server. I confirmed this by setting the Timeout to 10 seconds as well as 10000 seconds, and the behavior was as exepected.

I found a link to Martin's bug report, and the included patch applied to both our 1.3.20 and 1.3.24 servers fixed the problem. For some reason this bug was missed or ignored, but it or something like it should be added the next Apache release in order to fix this issue.

Do you need help?X

the patch to the 1.3.9 tree
(proxy_http.c):


  • 355,362 ****
    /* send the request data, if any. */
      if (ap_should_client_block(r)) {
!       while ((i = ap_get_client_block(r, buffer, sizeof buffer)) > 0)
            ap_bwrite(f, buffer, i);
      }
      ap_bflush(f);
      ap_kill_timeout(r);

--- 338,347 ----
/* send the request data, if any. */
      if (ap_should_client_block(r)) {
!       while ((i = ap_get_client_block(r, buffer, sizeof buffer)) > 0) {
!             ap_reset_timeout(r);
            ap_bwrite(f, buffer, i);
+         }
      }
      ap_bflush(f);
      ap_kill_timeout(r);

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org For additional commands, e-mail: bugs-help@httpd.apache.org Received on Thu Mar 28 12:21:46 2002

This archive was generated by hypermail 2.1.8 : Wed Aug 23 2006 - 16:43:02 EDT


Contact Us  Legal Notices  Order Services Online 
Pantek Home  Privacy Policy  IT news  Site Map  Pantek Library