<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Jul 20, 2015 at 3:32 PM, Robert L. Harris <span dir="ltr">&lt;<a href="mailto:robert.l.harris@gmail.com" target="_blank">robert.l.harris@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Guys,<div>  I&#39;m setting up an HAProxy to balance between some web servers.  Working great with a least-used mode.</div><div><br></div><div>  The next step is to balance between 2 databases but I don&#39;t want them in a  round robin or even &#39;normal&#39; balancing.  The DBA&#39;s are setting up one-way data replication only ( long argument they are refusing to explain ).  So I need to have 2 hosts in a &#39;cluster&#39; with HostA as the single/primary and if it goes down, fail over to HostB.  If HostA comes back up, do NOT fail back to HostA until manually told to do so ( data re-sync, etc ).</div><div><br></div><div>Any thoughts?  I don&#39;t see an option to configure HAproxy in this type of config.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Robert</div></font></span></div></blockquote><div><br></div><div>I did something like this a few years ago; basically use a Virtual IP and have something/someone do a failover of the VIP. In our case it was the Service Desk, but you could script it as well. Just have the primary node not assume the VIP if it reboots. Some DB HA setups use private interconnects so you could have them test for the other DB, etc.<br><br></div><div>This is not the absolute fastest failover, but it does work. <br><br></div><div>Leam <br></div></div><br>-- <br><div class="gmail_signature"><div><a href="http://leamhall.blogspot.com/" target="_blank">Mind on a Mission</a></div></div>
</div></div>