Re: virtual_server_group does that do what I think is does?

Todd Fleisher <[email protected]>
Newsgroups gmane.linux.keepalived.devel
Message-ID <[email protected]>
On Jul 23, 2014, at 8:19 AM, Mike Williams wrote:

> Sorry if this is the wrong place for idiot user questions, there isn't a 
> keepalived-users list and other people seem to be asking user-type questions 
> here.
> 
> So I'm looking to swap from ldirectord to keepalived.
> 
> One particular point confusing me no end is virtual_server_group.
> It seems like a slam dunk feature, but my puny brain can't grasp how to 
> actually use it.

I use this feature extensively and can hopefully help you understand with an example:

virtual_server_group VIP01 {
        x.x.x.x 80
        x.x.x.y 80
}

virtual_server group VIP01 {
        delay_loop 10
        lb_algo wrr
        lb_kind NAT
        protocol TCP

        real_server 10.x.x.x 80 {
                weight 10
                TCP_CHECK {
                        connect_timeout 3
                }
        }
        real_server 10.x.x.y 80 {
                weight 10
                TCP_CHECK {
                        connect_timeout 3
                }
        }
}

In this example, there are 2 VIP's (x.x.x.x:80 & x.x.x.y:80) with common real servers (10.x.x.x:80 & 10.x.x.y:80). Now you could keep adding new IP & port combinations into the vritual_server_group VIP01 stanza and they would all get the same real servers.  I'm not 100% sure if this reduces the number of checks from N to 1 ... but I would think/hope it does. Hope this helps.

-T



------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
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.