[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-httpd-users
Subject:    Re: [users@httpd] Checking backend downtime
From:       Suvendu Sekhar Mondal <suv3ndu () gmail ! com>
Date:       2019-03-06 16:43:42
Message-ID: CAP-JJ3rWGdNWntpCzOWkgG5hmjwNuQRo-ffHr6JeafT5EtHMjA () mail ! gmail ! com
[Download RAW message or body]

On Fri, Mar 1, 2019, 9:20 PM Paweł Cholewiński <pawelcholewinski@wp.pl
wrote:

> Hello,
>
>
> I configured proxy with proxy loadbalancer to route traffic to backend
> application servers.
>
> Balancer members do not detect the unavailability of the backend
> (downtime) and directs traffic to the broken node. As a result, users are
> waiting for a response from the broken backend servers.
>
> I want the balancer member to change its state to Err when detect backend
> downtime. I read in the documentation (
> https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypass), that the
> unavailability of the backend should be examined using the ping parameter.
>
> ping .. "This feature has been added to avoid problems with hung and busy
> backends."..
>
> When defining a balancer member, I use the ping option:
>
> ProxyPass "/" "balancer://test-site-local-balancer/"
>
> <Proxy "balancer://test-site-local-balancer">
>
> BalancerMember "http://127.0.0.1:2010" ping=2
>
> ..
>
Pawel,

I hope you are not using sticky session. That usually cause this type of
problem.

Another thing I can see that you have not set any RETRY value explicitly
for the balancer member. Apache will continue to use the default value
zero, which means continuous retry even the server is down. Please set
RETRY value to 300sec or something like that and re-test. Later you can
tune it as per your requirement.

> The configuration does not work as I expected – loadbalancer still directs
> traffic to the unavailable node. I'm listening packets using tcpdump and I
> do not see additional packets to port 2010 which should be associated with
> ping HTTP/1.1 100-Continue requests.
>
> I use Debian 10 with Server version: Apache/2.4.38 (Debian).
>
> How to setup ping mechanism correctly to detects unavailable backend
> servers?
>
> Thanks,
> Paweł
>
>

[Attachment #3 (text/html)]

<div dir="auto"><div><br><br><div class="gmail_quote"><div dir="ltr">On Fri, Mar 1, \
2019, 9:20 PM Paweł Cholewiński &lt;<a href="mailto:pawelcholewinski@wp.pl" \
target="_blank" rel="noreferrer">pawelcholewinski@wp.pl</a> \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 \
.8ex;border-left:1px #ccc solid;padding-left:1ex">







<div style="margin-bottom:45px">
    <div style="font-size:10pt"><p \
style="margin-bottom:0in;line-height:100%">Hello,<br></p><p \
style="margin-bottom:0in;line-height:100%"><br></p><div>I configured proxy with proxy \
loadbalancer to route traffic to backend application servers.<br></div><p \
style="margin-bottom:0in;line-height:100%">Balancer members do not detect the \
unavailability of the backend (downtime) and directs traffic to the broken node. As a \
result, users are waiting for a response from the broken backend servers.<br></p><p \
style="margin-bottom:0in;line-height:100%"></p><div>I want the balancer member to \
change its state to Err when detect backend downtime. I read in the documentation
(<a href="https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypass" \
rel="noreferrer noreferrer" \
target="_blank">https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypass</a>), \
that the unavailability of the backend should be examined using the ping \
parameter.<br></div><div> <br></div><div> ping	.. "This feature has been added to \
avoid problems with hung and busy backends."..<br></div><div> <br></div><div> When \
defining a balancer member, I use the ping option:<br></div><p></p><p \
style="margin-bottom:0in;line-height:100%">ProxyPass &quot;/&quot; \
&quot;balancer://test-site-local-balancer/&quot;<br></p><p \
style="margin-bottom:0in;line-height:100%">&lt;Proxy \
&quot;balancer://test-site-local-balancer&quot;&gt;<br></p><p \
style="margin-bottom:0in;line-height:100%">BalancerMember &quot;<a \
href="http://127.0.0.1:2010" rel="noreferrer noreferrer" \
target="_blank">http://127.0.0.1:2010</a>&quot; ping=2<br></p><p \
style="margin-bottom:0in;line-height:100%">..<br></p></div></div></blockquote></div></div><div \
dir="auto">Pawel,</div><div dir="auto"><br></div><div dir="auto">I hope you are not \
using sticky session. That usually cause this type of problem.</div><div \
dir="auto"><br></div><div dir="auto">Another thing I can see that you have not set \
any RETRY value explicitly for the balancer member. Apache will continue to use the \
default value zero, which means continuous retry even the server is down. Please set \
RETRY value to 300sec or something like that and re-test. Later you can tune it as \
per your requirement.</div><div dir="auto"><div class="gmail_quote"><blockquote \
class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc \
solid;padding-left:1ex"><div style="margin-bottom:45px"><div \
style="font-size:10pt"><p style="margin-bottom:0in;line-height:100%"></p><p \
style="margin-bottom:0in;line-height:100%">The configuration does not work as I \
expected – loadbalancer still directs traffic to the unavailable node. I&#39;m \
listening packets using tcpdump and I do not see additional packets to port 2010 \
which should be associated with ping HTTP/1.1 100-Continue requests.<br></p><p \
style="margin-bottom:0in;line-height:100%">I use Debian 10 with Server version: \
Apache/2.4.38 (Debian).<br></p><p style="margin-bottom:0in;line-height:100%">How to \
setup ping mechanism correctly to detects unavailable backend \
servers?<br></p><div><br></div><div>Thanks,<br></div><div>Paweł<br></div> <div \
dir="auto"><br></div></div>


</div></blockquote></div></div></div>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic