# HAPROXY send 2 requests at time (roundrobin strange behavior )

**URL:** <https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254>\
**Category:** Help!\
**Created:** [November 23, 2018, 2:42pm UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254 "2018-11-23T14:42:47Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![AMAUSER](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@AMAUSER](https://discourse.haproxy.org/u/AMAUSER)\
**Post date:** [November 23, 2018, 2:42pm UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/1 "2018-11-23T14:42:47Z")

</div>

Hello,

I’m novice in HAPROXY, i’am using 1.8 V  
bellow my roundrobin configuration :

=========================  
global  
log /dev/log local0  
log /dev/log local1 notice  
chroot /var/lib/haproxy  
stats socket /run/haproxy/admin.sock mode 660 level admin expose-fd listeners  
stats timeout 30s  
user haproxy  
group haproxy  
daemon

defaults  
log global  
mode http  
option httplog  
option dontlognull  
timeout connect 5000  
timeout client 50000  
timeout server 50000  
errorfile 400 /etc/haproxy/errors/400.http  
errorfile 403 /etc/haproxy/errors/403.http  
errorfile 408 /etc/haproxy/errors/408.http  
errorfile 500 /etc/haproxy/errors/500.http  
errorfile 502 /etc/haproxy/errors/502.http  
errorfile 503 /etc/haproxy/errors/503.http  
errorfile 504 /etc/haproxy/errors/504.http  
option forwardfor  
option http-server-close

frontend Loadbalancer\_Prod  
bind \*:80  
mode http  
default\_backend Nodes\_Prod

backend Nodes\_Prod  
mode http  
balance roundrobin  
option forwardfor  
server AMASERVER1 x.x.x.x:port1 check  
server AMASERVER2 x.x.x.x:port2 check

frontend Loadbalancer\_Test  
bind \*:8080  
mode http  
default\_backend Nodes\_Test

backend Nodes\_Test  
mode http  
balance roundrobin  
option forwardfor  
server AMASERVER1 x.x.x.x:port1 check  
server AMASERVER2 x.x.x.x:port2 check

listen stats  
bind \*:88  
mode http  
stats enable  
stats uri /stats  
stats realm HAProxy\ Statistics  
stats auth admin:admin

=============================  
The problem is when i use my Haproxy’s link one time and i see at stats i found that my proxy send tow requests at time for both servers 1 & 2 not in turns as should be in roundrobin mode

Did you have any solution for me ?

Thanks

---

<div class="post-metadata">

**Author:** ![lukastribus](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@lukastribus](https://discourse.haproxy.org/u/lukastribus)\
**Post date:** [November 25, 2018, 11:24am UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/2 "2018-11-25T11:24:26Z")

</div>

I’m not sure what you are saying. Can you provide the logs and explain based on the logs the difference between what you see and what you expect?

---

<div class="post-metadata">

**Author:** ![AMAUSER](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@AMAUSER](https://discourse.haproxy.org/u/AMAUSER)\
**Post date:** [November 26, 2018, 9:32am UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/3 "2018-11-26T09:32:18Z")

</div>

When i send one http request from my **[LBalanced.link.com](http://LBalanced.link.com)** i have this in my stats :  
 ![lb-after](https://us1.discourse-cdn.com/flex016/uploads/haproxy/original/1X/e26b1390cc4f9205b5ec434594817aef40dee94f.png)

what i expact is to see only 1 request for SERVER1 and 0 request for SERVER2  
So for me Roundrobin is not working and don’t know what wrong with my conf ?!

---

<div class="post-metadata">

**Author:** ![lukastribus](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@lukastribus](https://discourse.haproxy.org/u/lukastribus)\
**Post date:** [November 26, 2018, 7:06pm UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/4 "2018-11-26T19:06:39Z")

</div>

I assume those are two different requests.

Check the haproxy logs, to get more informations.

---

<div class="post-metadata">

**Author:** ![AMAUSER](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@AMAUSER](https://discourse.haproxy.org/u/AMAUSER)\
**Post date:** [November 27, 2018, 9:56am UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/5 "2018-11-27T09:56:25Z")

</div>

Yes this is the problem, when i send one request from my [LBalanced.link.com](http://LBalanced.link.com) logs say that :

Nov 27 10:49:08 localhost haproxy[8981]: My\_@IP:50209 [27/Nov/2018:10:49:08.570] Loadbalancer\_Prod Nodes\_Prod/SERVER1 0/0/1/1/50 200 55719 - - ---- 1/1/0/0/0 0/0 “GET / HTTP/1.1”  
Nov 27 10:49:09 localhost haproxy[8981]: My\_@IP:50209 [27/Nov/2018:10:49:09.112] Loadbalancer\_Prod Nodes\_Prod/SERVER2 0/0/1/2/4 200 55719 - - ---- 1/1/0/0/0 0/0 “GET /favicon.ico HTTP/1.1”

So effectively my loadbalancer re-send 2 requests when i send him only one  
Did you have any idea what can be the root cause ? or at least can you confirm if my config is good ?

Thank you

---

<div class="post-metadata">

**Author:** ![rhada](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/rhada/32/585_2.png) [@rhada](https://discourse.haproxy.org/u/rhada)\
**Post date:** [November 27, 2018, 1:13pm UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/6 "2018-11-27T13:13:13Z")

</div>

Hello,

You have 2 differents requests here :  
1 for / and second one for favicon

Everything looks fine for me.

---

<div class="post-metadata">

**Author:** ![AMAUSER](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@AMAUSER](https://discourse.haproxy.org/u/AMAUSER)\
**Post date:** [November 27, 2018, 2:01pm UTC](https://discourse.haproxy.org/t/haproxy-send-2-requests-at-time-roundrobin-strange-behavior/3254/7 "2018-11-27T14:01:06Z")

</div>

Ok i understand  
Thank you for your help
