I have a backend with long running php scripts. Anything above 60s results in a 504 error.
HAProxy v1.8.15
defaults
mode http
log global
option httplog
option dontlognull
option forwardfor except 127.0.0.0/8
option redispatch
retries 3
timeout http-request 15m
timeout queue 1m
timeout connect 10s
timeout client 65s
timeout server 65s
timeout tunnel 65s
timeout http-keep-alive 10s
timeout check 10s
maxconn 3000
I’ve tried tweaking the timeout client/server/tunnel, starting at 30 seconds and slowly incrementing up to 60 seconds. That works great. Anything above 60 seconds seems to be ignored, and I see a 504 error on the client.
Oct 28 01:48:33 localhost haproxy[34486]: [IP REDACTED]:17279 [28/Oct/2019:01:48:03.929] main~ hc/hc 0/0/2/-1/30005 504 194 - - sH-- 1/1/0/0/0 0/0 “GET /tools/z_scripts/timeout_test.php HTTP/1.1”
Oct 28 01:50:13 localhost haproxy[34610]: [IP REDACTED]:7454 [28/Oct/2019:01:49:28.560] main~ hc/hc 0/0/3/-1/45004 504 194 - - sH-- 3/3/0/0/0 0/0 “GET /tools/z_scripts/timeout_test.php HTTP/1.1”
Oct 28 01:52:22 localhost haproxy[34717]: [IP REDACTED]:3619 [28/Oct/2019:01:51:27.248] main~ hc/hc 0/0/2/-1/55004 504 194 - - sH-- 1/1/0/0/0 0/0 “GET /tools/z_scripts/timeout_test.php HTTP/1.1”
Oct 28 01:54:10 localhost haproxy[34805]: [IP REDACTED]:12123 [28/Oct/2019:01:53:10.755] main~ hc/hc 0/0/3/60059/60062 504 428 - - ---- 1/1/0/1/0 0/0 “GET /tools/z_scripts/timeout_test.php HTTP/1.1”
the first three are from sub-60 second timeout settings. the last one is using 65 seconds.
I’m pulling my hair out here… any ideas?