On Mon, Jan 12, 2015 at 9:03 PM, Srinivas Kotaru <kotar...@gmail.com> wrote:
> Baptiste <bedis9@...> writes:
>
>>
>> On Thu, Jan 8, 2015 at 10:16 PM, Srinivas Kotaru <kotarusv@...> wrote:
>> > Srinivas Kotaru <kotarusv <at> ...> writes:
>> >
>> >>
>> >> I hit similar issue of below post. Any solution yet?
>> >>
>> >> http://serverdown.ttwait.com/que/594669
>> >>
>> >>
>> >
>> >
>> > Sample
>> >
>> > backend sales_cluster
>> > http-send-name-header Host
>> > balance roundrobin
>> > option httpchk HEAD /pingpong.html HTTP/1.1\r\n
>> > http-check expect ! rstatus ^5
>> > cookie SERVERID insert indirect nocache
>> > server app1.example.com  app1hello-xxxx:80 check cookie server1
>> > server app2.example.com  app1hello-xxxx:80 check cookie server2
>> >
>> > with above config, HAProxy sending right Host headers
>> > like app1.example.com and app2.example.com
>> > but httpchk not sending any valid host header. I cannot put both
>> > app1.example.com and app2.example.com in same httpchk statement.
>> >
>> >
>>
>> hi
>>
>> From the doc, it is said nowhere that this header should be sent
>> during health check.
>>
>> There is a very dirty workaround to do what you want: is to "offload"
>> monitoring into a dedicated backend (one per server).
>>
>> Baptiste
>>
>>
>
>
> Baptiste
>
> It really doesn't my problem. I have lot of clients. I can't build another
> monitoring solution on top of it for each stack.  Even you do that, it
> becomes manual failover per app basis.
>
>
> with above example I can only check heath of one application even though
> it has 2 servers. if second goes down, without proper health checkes,
> HAProxy still send clietn traffic to 2nd server and get 503 errors.
>
> The olnly solution I can think off
>
> 1. http-send-name-header should send appropriate Host header to probes
>  ( Or)
>
> 2. I shoud be abel to send 2 or more httpchk host headers rather than 1.
> which is current limitation. If I can set httpchk at server level rather 
> backend
> level, it solve the problem
>
> Srinivas Kotaru
>
>


so what you want ot do is content switching: one application per
backend (hence a single server in your backend) with a dedicated
health check and route only http requests related to this application.

you don't need load-balancing at all!

Baptiste

Reply via email to