<div dir="ltr">Hey,<div><br></div><div> Ok so I took your advice and changed the value to 5 ms. And yeah, honestly I kind of just mindlessly pasted an example I found on the web into my VCL. It's late here and I want to go to bed. But the curiosity I have on how to solve this is killing me! ;)</div>
<div><br></div><div>And I would think that giving the servers longer to time out would actually help varnish realize the server is ok. Which in fact it appears to be. But for the sake of argument I tried changing the values to what you suggest and bounced varnish. No change yet. </div>
<div><br></div><div><div>backend web1 {</div><div> .host = "10.10.1.94";</div><div> .port = "80";</div><div> .probe = {</div><div> .url = "/healthcheck.html";</div><div> .timeout = 5 ms;</div>
<div> .interval = 1s;</div><div> .window = 10;</div><div> .threshold = 8;</div><div> }</div><div>}</div><div><br></div><div>backend web2 {</div><div><br></div><div> .host = "10.10.1.98";</div>
<div> .port = "80";</div><div> .probe = {</div><div> .url = "/healthcheck.html";</div><div> .timeout = 5 ms;</div><div> .interval = 1s;</div><div> .window = 10;</div>
<div> .threshold = 8;</div><div> }</div><div>}</div><div><br></div><div>director www client {</div><div> { .backend = web1 ; .weight = 2; }</div><div> { .backend = web2 ; .weight = 2; }</div><div> }</div>
</div><div><br></div><div>So like I said no expected change and none produced. </div><div><br></div><div><div>[root@varnish1:/etc/varnish] #varnishlog | grep web2</div><div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div>
<div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div><div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div><div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div>
<div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div><div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div><div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div>
<div> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000</div></div><div><br></div><div>Thanks</div><div>Tim</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, May 12, 2014 at 11:13 PM, Stefan Caunter <span dir="ltr"><<a href="mailto:stef@scaleengine.com" target="_blank">stef@scaleengine.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">34 milliseconds? You are asking for your backend to get marked sick<br>
all the time with this value on an apache server. You just want to<br>
know if it has totally gone away. Set the timeout to 5 seconds. You<br>
can do some beautiful tuning if you really understand your web app and<br>
want to move varnish away from sick backends, but for now, you just<br>
need to use both your backends, and let varnish protect them.<br>
<br>
<br>
----<br>
<br>
Stefan Caunter<br>
ScaleEngine Inc.<br>
E: <a href="mailto:stefan.caunter@scaleengine.com">stefan.caunter@scaleengine.com</a><br>
Toronto Canada<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
On Mon, May 12, 2014 at 11:03 PM, Tim Dunphy <<a href="mailto:bluethundr@gmail.com">bluethundr@gmail.com</a>> wrote:<br>
> Hi Nick,<br>
><br>
> Thanks for your reply! I tried a different probe. No luck so far:<br>
><br>
> backend web1 {<br>
> .host = "10.10.1.94";<br>
> .port = "80";<br>
> .probe = {<br>
> .url = "/healthcheck.html";<br>
> .timeout = 34 ms;<br>
> .interval = 1s;<br>
> .window = 10;<br>
> .threshold = 8;<br>
> }<br>
> }<br>
><br>
> backend web2 {<br>
><br>
> .host = "10.10.1.98";<br>
> .port = "80";<br>
> .probe = {<br>
> .url = "/healthcheck.html";<br>
> .timeout = 34 ms;<br>
> .interval = 1s;<br>
> .window = 10;<br>
> .threshold = 8;<br>
> }<br>
> }<br>
><br>
> director www client {<br>
> { .backend = web1 ; .weight = 2; }<br>
> { .backend = web2 ; .weight = 2; }<br>
> }<br>
><br>
><br>
> This is all the healthcheck file does:<br>
><br>
> [root@beta:/var/www/jf-ref] #cat healthcheck.html<br>
> good<br>
><br>
> Drum roll please!! AAAAnnnnnd:<br>
><br>
> [root@varnish1:/etc/varnish] #varnishlog | grep web2<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
> 0 Backend_health - web2 Still sick ------- 0 8 10 0.000000 0.000000<br>
><br>
> Bummer. :(<br>
><br>
> No joy at all.<br>
><br>
> Thanks for playing!<br>
> Tim<br>
><br>
><br>
> On Mon, May 12, 2014 at 10:03 PM, nick tailor <<a href="mailto:nick.tailor@gmail.com">nick.tailor@gmail.com</a>> wrote:<br>
>><br>
>> Try using a custom health check probe<br>
>><br>
>> On May 9, 2014 10:00 PM, "Tim Dunphy" <<a href="mailto:bluethundr@gmail.com">bluethundr@gmail.com</a>> wrote:<br>
>>><br>
>>> Hey all,<br>
>>><br>
>>> I have two web backends in my varnish config. And one node is reporting<br>
>>> healthy and the other is being reported as 'sick'.<br>
>>><br>
>>> 10 Backend c 11 www web1<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001130 0.001067<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001231 0.001108<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001250 0.001143<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001127 0.001139<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001208 0.001157<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001562 0.001258<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001545 0.001330<br>
>>> HTTP/1.1 200 OK<br>
>>> 0 Backend_health - web1 Still healthy 4--X-RH 5 3 5 0.001363 0.001338<br>
>>> HTTP/1.1 200 OK<br>
>>> 11 BackendClose b web1<br>
>>><br>
>>> [root@varnish1:/etc/varnish] #varnishlog | grep web2<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>> 0 Backend_health - web2 Still sick 4--X--- 0 3 5 0.000000 0.000000<br>
>>><br>
>>> And I'm really at a loss to understand why. Both nodes should be<br>
>>> completely identical. And the web roots on both are basically svn repos that<br>
>>> are in sync.<br>
>>><br>
>>> From web1 :<br>
>>><br>
>>> [root@beta:/var/www/jf-current] #svn info | grep -i revision<br>
>>> Revision: 17<br>
>>><br>
>>> To web2:<br>
>>><br>
>>> [root@beta-new:/var/www/jf-current] #svn info | grep -i revision<br>
>>> Revision: 17<br>
>>><br>
>>> This is the part of my vcl file where I define the web back ends:<br>
>>><br>
>>> probe favicon {<br>
>>> .url = "/favicon.ico";<br>
>>> .timeout = 60ms;<br>
>>> .interval = 2s;<br>
>>> .window = 5;<br>
>>> .threshold = 3;<br>
>>> }<br>
>>><br>
>>> backend web1 {<br>
>>> .host = "xx.xx.xx.xx";<br>
>>> .port = "80";<br>
>>> .probe = favicon;<br>
>>> }<br>
>>><br>
>>> backend web2 {<br>
>>><br>
>>> .host = "xx.xx.xx.xx";<br>
>>> .port = "80";<br>
>>> .probe = favicon;<br>
>>> }<br>
>>><br>
>>> And the file that varnish is probing for is present on both:<br>
>>><br>
>>> [root@beta:/var/www/jf-current] #ls -l /var/www/jf-current/favicon.ico<br>
>>> -rwxrwxr-x 1 apache ftp 1150 Dec 22 00:53 /var/www/jf-current/favicon.ico<br>
>>><br>
>>> I've also setup individual web URLs for each host that isn't cached in<br>
>>> varnish so I can hit each one. And each site comes up ok. So I'm a little<br>
>>> puzzled as to why the second web host is reporting 'sick' and what I can do<br>
>>> to get it back into load balancing.<br>
>>><br>
>>> Thanks for any help you can provide!<br>
>>><br>
>>> Tim<br>
>>><br>
>>><br>
>>><br>
>>><br>
>>><br>
>>> --<br>
>>> GPG me!!<br>
>>><br>
>>> gpg --keyserver <a href="http://pool.sks-keyservers.net" target="_blank">pool.sks-keyservers.net</a> --recv-keys F186197B<br>
>>><br>
>>><br>
>>> _______________________________________________<br>
>>> varnish-misc mailing list<br>
>>> <a href="mailto:varnish-misc@varnish-cache.org">varnish-misc@varnish-cache.org</a><br>
>>> <a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" target="_blank">https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc</a><br>
><br>
><br>
><br>
><br>
> --<br>
> GPG me!!<br>
><br>
> gpg --keyserver <a href="http://pool.sks-keyservers.net" target="_blank">pool.sks-keyservers.net</a> --recv-keys F186197B<br>
><br>
><br>
> _______________________________________________<br>
> varnish-misc mailing list<br>
> <a href="mailto:varnish-misc@varnish-cache.org">varnish-misc@varnish-cache.org</a><br>
> <a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" target="_blank">https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>GPG me!!<br><br>gpg --keyserver <a href="http://pool.sks-keyservers.net" target="_blank">pool.sks-keyservers.net</a> --recv-keys F186197B<br><br>
</div>