It should be possible, I believe there's an option to have health checks go to a different port than the main connections go to. Then you'd just need a daemon on that same machine, listening on a different port, which can check the server's status and return a success or failure.
On Thu, Jan 8, 2009 at 2:01 PM, Eric Schwab <[email protected]> wrote: > We are using haproxy to load balance inbound SMTP traffic across several > servers. At present the load-balancing is done via the 'leastconn' > algorithm within haproxy. > > We are trying to add some intelligence to give us control over how inbound > SMTP traffic is routed in the event that one or more of those SMTP servers > are in a sub-optimal state, and that state cannot be determined from a > simple connection (or lack thereof) to port 25. > > (As a simple example, one of the servers may have a very high queue, which > would not impact its ability to receive new messages via port 25, but we > would want to reduce traffic to that particular server.) Without going into > too much more detail, the load-balancing algorithms within haproxy will not > have sufficient information to reroute traffic the way we would like to. > > The ideal scenario for us would be for haproxy to issue an HTTP check (even > though the incoming connections are for an smtp service) to a destination > server in the pool, and upon receiving a 4xx or 5xx level response, haproxy > would pull that server out of the pool, thus not allowing new SMTP > connections -- however not terminating existing connections. > > Is this possible? > > > > -- > > Eric Schwab > Internet Integration, Inc. > http://www.i-3.com > Tel: 310-571-3200 > Fax: 310-571-3434 > >

