Re: Keepalived for IP failover only (no load balancing)

"Ryan O'Hara" <[email protected]>
Newsgroups gmane.linux.keepalived.devel
Message-ID <[email protected]>
On Sun, Dec 08, 2013 at 07:55:09AM -0500, Aron West wrote:
> Hi everyone,
> 
> I have been testing Keepalived for the past couple of months on SLES 11sp2
> and haven't experienced any problems compiling or getting it running
> (including the latest release 1.29).  I have installed the SLES HA
> extensions, so the LVS patch has been applied to the Linux kernel.
> 
> I've been working on a two node active/passive setup with Keepalived health
> checks for monitoring Tomcat and Glassfish application servers. I have
> studied the options in the configuration file to answer the following
> question:  is there a simple way to disable load balancing and just rely on
> Keepalived for IP failover?  I would like my master node to stay the master
> until one of the monitored services (like Tomcat) fails in which case, the
> backup node takes over.  By default Keepalived uses round robin scheduling
> (rr), so even when no service has failed master and backup keep switching
> places.   I've searched extensively about this issue, experimented with
> nopreempt, setting different priorities, setting both nodes to backup
> etc.   I have found other posts on the Internet asking this question
> without any responses.
> 
> Thanks for any insights,
> 
> Aron

It is simple to use keepalived for IP failover only with no load
balancing. You simple defined your vrrp_instance and do not create any
virtual_servers. At least that is one way to do it. To monitor your
application and trigger IP failover, you will need to use a
vrrp_script. This is actually a common configuration for users who
want keepalived to handle IP failover but use haproxy for
load-balancing.

Your other alternative is to use something like Pacemaker. This is
probably better suited for what you are trying to accomplish.

Ryan


------------------------------------------------------------------------------
Sponsored by Intel(R) XDK 
Develop, test and display web and hybrid apps with a single code base.
Download it for free now!
http://pubads.g.doubleclick.net/gampad/clk?id=111408631&iu=/4140/ostg.clktrk
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.