Hi all, I am moving from using LXC to KVM for haproxy on my Debian 7 system. When I start haproxy, I get this error: _________________________________________ Apr 7 10:38:22 localhost haproxy[3418]: Proxy haproxy started. Apr 7 10:38:24 localhost haproxy[3420]: Server haproxy/nginx-1 is DOWN, reason Layer4 timeout, check duration: 2000ms. 1 active and 0 backup servers left. 0 essions active, 0 requeued, 0 remaining in queue. Apr 7 10:38:24 localhost haproxy[3419]: Server haproxy/nginx-1 is DOWN, reason Layer4 timeout, check duration: 2001ms. 1 active and 0 backup servers left. 0 essions active, 0 requeued, 0 remaining in queue. Apr 7 10:38:25 localhost haproxy[3420]: Server haproxy/nginx-2 is DOWN, reason Layer4 timeout, check duration: 2001ms. 0 active and 0 backup servers left. 0 essions active, 0 requeued, 0 remaining in queue. Apr 7 10:38:25 localhost haproxy[3420]: proxy haproxy has no server available! Apr 7 10:38:25 localhost haproxy[3419]: Server haproxy/nginx-2 is DOWN, reason Layer4 timeout, check duration: 2001ms. 0 active and 0 backup servers left. 0 essions active, 0 requeued, 0 remaining in queue. Apr 7 10:38:25 localhost haproxy[3419]: proxy haproxy has no server available!
>From outside the haproxy, I get the error: # wget 192.168.122.112:80 --2015-04-07 10:48:47-- http://192.168.122.112/ Connecting to 192.168.122.112:80... connected. HTTP request sent, awaiting response... 503 Service Unavailable 2015-04-07 10:48:47 ERROR 503: Service Unavailable. _______________________________________________________________ The config file is: global log 127.0.0.1 local0 log 127.0.0.1 local1 notice maxconn 65536 daemon quiet nbproc 2 debug user haproxy group haproxy defaults log global mode http option dontlognull retries 3 option redispatch maxconn 65536 timeout connect 5000 timeout client 50000 timeout server 50000 #listen haproxy 192.168.122.112:80 listen haproxy *:80 mode http stats enable stats auth someuser:somepassword balance roundrobin option prefer-last-server option forwardfor option httpchk HEAD /check.txt HTTP/1.0 server nginx-1 192.168.122.101:80 check server nginx-2 192.168.122.102:80 check BTW, I could not use "listen haproxy 192.168.122.112:80", but had to use *:80 as haproxy does not start up with the former. It seems like haproxy startup is happening ahead of networking. ______________________________________________________ I also stopped/restarted haproxy, but I still get the same error at start. root@haproxy-2:~# netstat -apn | grep :80 tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 3558/haproxy _______________________________________________________________ >From outside haproxy, I can do a wget/curl" to either of the two servers: # wget 192.168.122.101:80 --2015-04-07 10:42:28-- http://192.168.122.101/ Connecting to 192.168.122.101:80... connected. HTTP request sent, awaiting response... 200 OK Length: 867 [text/html] Saving to: `index.html' 100%[======================================>] 867 --.-K/s in 0s 2015-04-07 10:42:28 (104 MB/s) - `index.html' saved [867/867] _______________________________________________________________ And I can do the same from haproxy: root@haproxy-2:~# wget 192.168.122.101 --2015-04-07 10:43:48-- http://192.168.122.101/ Connecting to 192.168.122.101:80... connected. HTTP request sent, awaiting response... 200 OK Length: 867 [text/html] Saving to: `index.html' 100%[======================================>] 867 --.-K/s in 0s 2015-04-07 10:43:48 (80.3 MB/s) - `index.html' saved [867/867] _______________________________________________________________ How do I fix this problem? Thank you, - KK

