TCP mode failover?

From: Aaron Blohowiak <>
Date: Fri, 27 May 2011 16:46:05 -0700

Sorry if I'm being daft, but I've read the manual, experimented, asked in IRC and still have not sorted out my HAProxy config.

Here's my config:

What I want to happen:
  requests should go to server "master" exclusively. If master ever refuses a connection, then fail to "slave" and never proxy any requests to "master" ever again.

What happens:
  requests correctly go to "master" exclusively. If master refuses a connection, clients get ERCONNREFUSED. =(

if i use the admin socket to connect and say that "master" failed, then connections are correctly made to "slave".

I thought that the "observe layer4" would cause master to fail if any of the connections to it failed, but that doesn't seem to be the case. "master" and "slave" do not implement http, smtp or ssl so the "check" methods in the manual are out of the question. (the backend server is redis.)

Do i have to have a separate monitor process that will kick master out of HAProxy's active server list, or did i somehow mess up my config?


Received on 2011/05/28 01:46

This archive was generated by hypermail 2.2.0 : 2011/05/28 02:00 CEST