Hi,
whenever “systemctl reload haproxy” is executed, one or two http requests are dropped.
The load was light it was about 2 requests per second.
Please help me to fix this problem.
I attached haproxy.cfg and /etc/init.d/haproxy files
http requets log:
REQ-0735|14:57:55|14:58:05|X-Helix-Server: vealasr-e0000C2| “Status”: “OK”|http_code=200|time_connect=0.062|time_starttransfer=0.375|time_total=10.923
REQ-0737|14:57:56|14:58:06|X-Helix-Server: vealasr-e000000| “Status”:
“OK”|http_code=200|time_connect=0.063|time_starttransfer=0.371|time_total=10.500
REQ-0753|14:58:06|14:58:06||http_code=000|time_connect=0.052|time_starttransfer=0.000|time_total=0.201
REQ-0736|14:57:55|14:58:07|X-Helix-Server: vealasr-e00005D| “Status”: “OK”|http_code=200|time_connect=0.063|time_starttransfer=0.379|time_total=11.314
REQ-0738|14:57:57|14:58:07|X-Helix-Server: vealasr-e0000C2| “Status”: “OK”|http_code=200|time_connect=0.062|time_starttransfer=0.366|time_total=10.784
Here is the haproxy.cfg
global
master-worker
chroot /var/lib/haproxy
user haproxy
group haproxy
maxconn 5000
pidfile /var/run/haproxy.pid
turn on stats unix socket
stats socket /var/lib/haproxy/stats
stats socket /var/run/haproxy.sock mode 600 expose-fd listeners level user
log 127.0.0.1 local2
defaults
mode http
maxconn 5000
log global
option httplog
option redispatch
option dontlognull
option http-server-close
timeout http-request 10s
timeout check 10s
timeout connect 10s
timeout client 1m
timeout queue 1m
timeout server 4m
timeout http-keep-alive 10s
retries 6
frontend app_front
mode tcp
bind *:8443
default_backend app_backend
frontend stats
mode http
bind *:8404
stats enable
stats uri /stats
stats hide-version
stats refresh 30s
backend app_backend
mode tcp
balance leastconn
option httpchk GET /alive
http-check expect status 200
default-server inter 5s fall 2 rise 2
server server-1 10.30.1.1:8080 check port 9095
server server-2 10.30.1.2:8080 check port 9095
/etc/init.d/haproxy:
start() {
quiet_check
if [ $? -ne 0 ]; then
echo “Errors found in configuration file, check it with ‘$BASENAME check’.”
return 1
fi
echo -n "Starting $BASENAME: "
daemon $BIN -W -D -f $CFG -p PIDFILE
RETVAL=?
echo
[ $RETVAL -eq 0 ] && touch $LOCKFILE
return $RETVAL
}
reload() {
if ! [ -s $PIDFILE ]; then
return 0
fi
quiet_check
if [ $? -ne 0 ]; then
echo “Errors found in configuration file, check it with ‘$BASENAME check’.”
return 1
fi
$BIN -D -f $CFG -x $SOCKETFILE -p PIDFILE -sf (cat $PIDFILE)
}