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 2009/07/20 15:45:46 UTC

DO NOT REPLY [Bug 47549] New: mod_proxy connectiontimeout setting does not works, code error

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

           Summary: mod_proxy connectiontimeout setting does not works,
                    code error
           Product: Apache httpd-2
           Version: 2.2.11
          Platform: Sun
        OS/Version: Solaris
            Status: NEW
          Severity: major
          Priority: P2
         Component: mod_proxy_http
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: jagusztinl@freemail.hu


We have the following setting in mod_proxy:


   BalancerMember http://server1:48080 route=sp_server1 connectiontimeout=3
timeout=120

   BalancerMember http://server2:48080 route=sp_server2 connectiontimeout=3
timeout=120

We tried it, but the tcp connection timeout does not works, in case of network
failure it waits much longer (few minutes) instead of 3 secs. We checked the
mod_prixy code, and found that it should be corrected.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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





--- Comment #2 from jagusztinl@freemail.hu  2009-08-03 14:05:14 PST ---
We had the following config:
<Proxy balancer://sp_cluster>
   BalancerMember http://t1:48080 route=sp_server1 timeout=120
   BalancerMember http://t2:48080 route=sp_server2 timeout=120
   ProxySet stickysession=JSESSIONID
</Proxy>

But we got:

Syntax error on line 12 of
/home/webapp/apache/conf/vh.spportal.sp_cluster.conf:

BalancerMember Connectiontimeout has wrong format
The configuration is not proper, so the server spportal_server cannot start!

We found that the bug somewhere here:

if (ap_timeout_parameter_parse(val, &timeout, "s") != APR_SUCCESS)
            return "Connectiontimeout has wrong format";

But it is very complicated..


But from another forum a similar problem with release 2.2.11:

Site index · List index
Message view     « Date » · « Thread »
Top     « Date » · « Thread »
>From     "Ian Lea" <ia...@gmail.com>
Subject     [users@httpd] 2.2.11: BalancerMember Ping/Pong timeout has wrong
format
Date     Wed, 31 Dec 2008 12:20:01 GMT

Hi


On apache 2.2.10 a config file with these lines

<Proxy balancer://xxx>
     BalancerMember ajp://localhost:17100 route=yyy ping=10
</Proxy>

works fine, but on 2.2.11 it fails to parse, showing error

Syntax error on line 73 of /opt/apache-2.2.11/conf/test.conf:
BalancerMember Ping/Pong timeout has wrong format


I see that the changes file includes

  mod_proxy: Add the possibility to set the worker parameters
  connectiontimeout and ping in milliseconds. [Ruediger Pluem]

If I've followed the code path correctly (far from certain),
server/util.c says that the following units are understood

* ms    : milliseconds
* s     : seconds
* mi[n] : minutes
* h     : hours

but adding any of those makes no difference - they all still fail with
the parse error.


Any suggestions?
Ian.
ian.lea@gmail.com


And also refer to this:
https://issues.apache.org/bugzilla/show_bug.cgi?id=46500

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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





--- Comment #3 from jagusztinl@freemail.hu  2009-08-03 14:12:47 PST ---
And found a possible solution on a forum:

....
Found the same issue here.

Have debugged the problem with gdb. In function
util.c:ap_timeout_parameter_parse
the first errno checking is true, so it returns an error to its caller.

The apr_strings.c:apr_strtoi64 function just above should clear the errno
variable at the beginning, I think.

The following patch against apr_strings.c works for me.

diff -uNr /httpd-2.2.11/srclib/apr/strings/apr_strings.c.orig \
/httpd-2.2.11/srclib/apr/strings/apr_strings.c
--- /httpd-2.2.11/srclib/apr/strings/apr_strings.c.orig  2006-08-03
+12:55:31.000000000 +0200
+++ /httpd-2.2.11/srclib/apr/strings/apr_strings.c       2009-01-14
+23:24:55.000000000 +0100
@@ -244,6 +244,7 @@

 APR_DECLARE(apr_int64_t) apr_strtoi64(const char *nptr, char **endptr, int
base)
 {
+    errno = 0;
 #ifdef APR_INT64_STRFN
     return APR_INT64_STRFN(nptr, endptr, base);
 #else

Regards,

Javi.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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


Ruediger Pluem <rp...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |RESOLVED
         Resolution|                            |FIXED


--- Comment #6 from Ruediger Pluem <rp...@apache.org> 2009-08-05 11:32:20 PDT ---
(In reply to comment #5)

> > This was a bug in apr. The version now bundled with 2.2.12 does not contain
> > this problem. So please retest with 2.2.12.
> 
> Just test the same configuration with version 2.2.12.
> The apr_strings.c seems to have been patched, but i still get the same error :
> 
> BalancerMember Ping/Pong timeout has wrong format
> 

I cannot reproduce this issue with 2.2.12. Either you use an older apr version
that is installed somewhere else on your system or you have any kind of crappy
characters in your config (maybe invisible to your editor).

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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

Wagner Sartori Junior <ws...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wsartori@gmail.com

--- Comment #7 from Wagner Sartori Junior <ws...@gmail.com> 2010-03-11 19:58:13 UTC ---
*** Bug 48893 has been marked as a duplicate of this bug. ***

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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


Ruediger Pluem <rp...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO




--- Comment #1 from Ruediger Pluem <rp...@apache.org>  2009-07-20 09:18:57 PST ---
If you already had a look at the code: Do you care to tell us were the changes
would need to be done?

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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





--- Comment #4 from Ruediger Pluem <rp...@apache.org>  2009-08-03 14:14:55 PST ---
(In reply to comment #2)

> 
> On apache 2.2.10 a config file with these lines
> 
> <Proxy balancer://xxx>
>      BalancerMember ajp://localhost:17100 route=yyy ping=10
> </Proxy>
> 
> works fine, but on 2.2.11 it fails to parse, showing error
> 

This was a bug in apr. The version now bundled with 2.2.12 does not contain
this problem. So please retest with 2.2.12.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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


DO NOT REPLY [Bug 47549] mod_proxy connectiontimeout setting does not works, code error

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



--- Comment #5 from f. gaillard <fg...@w3architect.com> 2009-08-05 09:16:09 PDT ---
(In reply to comment #4)
> (In reply to comment #2)
> 
> > 
> > On apache 2.2.10 a config file with these lines
> > 
> > <Proxy balancer://xxx>
> >      BalancerMember ajp://localhost:17100 route=yyy ping=10
> > </Proxy>
> > 
> > works fine, but on 2.2.11 it fails to parse, showing error
> > 
> 
> This was a bug in apr. The version now bundled with 2.2.12 does not contain
> this problem. So please retest with 2.2.12.

Just test the same configuration with version 2.2.12.
The apr_strings.c seems to have been patched, but i still get the same error :

BalancerMember Ping/Pong timeout has wrong format

Regards,

--Fabrice Gaillard

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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