I'm proposing roundrobin because it seems leastconn have side effects
in you case.
But we'll have a more accurate idea with the stats from the screenshot.

Baptiste

On Sat, Mar 1, 2014 at 6:36 PM, vijeesh vijayan
<vijeeshk.vija...@gmail.com> wrote:
> Thanks. will share screenshot shortly. roundrobin recommented for mysql
> also?
>
>
> On Fri, Feb 28, 2014 at 3:22 PM, Baptiste <bed...@gmail.com> wrote:
>>
>> Hi,
>>
>> this may be due to your load-balancing algorithm and the speed of your
>> servers.
>> leastconn applies to currently established connections, not to number
>> of connections established per second.
>>
>> could you enable haproxy stats page and share us (or to me directly) a
>> screenshot of it?
>>
>> You could give a try to 'balance roundrobin' and see what happens.
>>
>> Baptiste
>>
>>
>> On Fri, Feb 28, 2014 at 9:41 AM, vijeesh vijayan
>> <vijeeshk.vija...@gmail.com> wrote:
>> > we are using haproxy (1.4)to distribute traffic to 30 of our db nodes.
>> > we are facing an issue with weights.
>> >
>> > sample configs
>> >
>> > =========================
>> > defaults
>> >         mode           tcp
>> >         retries        2
>> >         option         redispatch
>> >         maxconn        256000
>> >         timeout        connect       10s
>> >         timeout        client        10s
>> >         timeout        server        10s
>> >
>> >
>> >         log global
>> >
>> >         option dontlognull
>> >
>> >
>> >
>> > listen newone :4000
>> >         mode tcp
>> >
>> >         balance leastconn
>> >         option mysql-check user abcd
>> >
>> >
>> > server    x.x.x.3:3306   weight 125   check inter 3s  rise 2  fall 2
>> >
>> > server y.com   x.x.x.4:3306   weight 12   check inter 3s  rise 2 fall 2
>> > server y.com   x.x.x.4:3306   weight 12   check inter 3s  rise 2 fall 2
>> > =====================
>> >
>> >
>> >  issue is we are getting only 150qps on server x.com even with weight
>> > 125.
>> >
>> > but on y.com we are getting 500qps with a weight of 12 , but mentioned
>> > twice.
>> >
>> >
>> > can you explain why it is so?
>> >
>> >
>> >
>> > --
>> > =========================
>> > Vijeesh K
>> > "The temptation to quit will be greatest just before you are about to
>> > succeed"
>
>
>
>
> --
> =========================
> Vijeesh K
> "The temptation to quit will be greatest just before you are about to
> succeed"

Reply via email to