Haproxy Force Reuse TCP Connections.

Job ID: 30842525

Budget: $30 – $250 USD

Hello,
I have haproxy installed on my server using these configurations:
-----------------------------------------------
global
maxconn 500000
nbthread 10
log /dev/log local0
log /dev/log local1 notice
chroot /var/lib/haproxy
stats timeout 30s
user haproxy
group haproxy
daemon
tune.ssl.cachesize 10000
# Default SSL material locations
ca-base /etc/ssl/certs
crt-base /etc/ssl/private
ssl-default-bind-ciphers ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:RSA+AESGCM:RSA+AES:!aNULL:!MD5:!DSS
ssl-default-bind-options no-sslv3
# tune.maxrewrite 16384
# tune.bufsize 32768

defaults
log global
mode http
option tcplog
option redispatch
retry-on all-retryable-errors
retries 5
option dontlognull
option accept-invalid-http-request
option accept-invalid-http-response
http-reuse always
timeout queue 30s
timeout tunnel 2m
timeout client-fin 1s
timeout server-fin 1s
timeout http-request 10s
timeout http-keep-alive 4s
timeout connect 5s
timeout client 15s
timeout server 300s

listen stats
bind *:9999
stats enable
stats hide-version
stats uri /haproxy_admin?stats
stats auth admin:123456
stats refresh 5s

frontend s_front
bind *:30000-34999
option httplog
option forwardfor
option http-keep-alive
default_backend s_back

backend s_back
option forwardfor
http-reuse always
option http-keep-alive
#server server1 127.0.0.1:12011 check
-----------------------------------------

However, when I sent requests, it will open a new connection for each request (Not Reused The Already Established Connections)

I want to reuse all Established connections without creating a new connection unless haproxy gets more than requests that established connections can be handled.

All the best
Related categories: System Admin Linux Apache Ubuntu Debian