fail over virtual_server ?
Jan-Frode Myklebust <[email protected]>
| Newsgroups | gmane.linux.keepalived.devel |
|---|---|
| Message-ID | <[email protected]> |
So far we've only been using keepalived to manage movable IP addresses,
and am now starting to look at also using virtual server.. I very much
like the idea of running the virtual_server on the same physical servers
as we're using for the backend services, and avoid another dedicated set
of servers in front of the real_servers, but I don't see how to achieve
this..
So, currently we have:
------------------------------------------------------------------------
vrrp_instance DNS_LAB_VIP {
state BACKUP
interface eth0
virtual_router_id 97
priority 100
advert_int 1
smtp_alert
authentication {
auth_type PASS
auth_pass passord
}
virtual_ipaddress {
109.247.115.97
}
track_script {
chk_named
}
}
virtual_server 109.247.115.97 53 {
delay_loop 6
lb_algo wrr
lb_kind DR
persistence_timeout 0
protocol TCP
ha_suspend
real_server 109.247.115.98 53 {
weight 1
notify_down "/sbin/ipvsadm -d -u 109.247.115.97:53 -r 109.247.115.98:53"
notify_up "/sbin/ipvsadm -a -u 109.247.115.97:53 -r 109.247.115.98:53 -g -w 1"
TCP_CHECK {
connect_timeout 6
}
}
real_server 109.247.115.99 53 {
weight 1
notify_down "/sbin/ipvsadm -d -u 109.247.115.97:53 -r 109.247.115.99:53"
notify_up "/sbin/ipvsadm -a -u 109.247.115.97:53 -r 109.247.115.99:53 -g -w 1"
TCP_CHECK {
connect_timeout 6
}
}
}
------------------------------------------------------------------------
This works fine when running on only one of the servers, but when
running same config on both servers it's looping. Problem is that now
both servers has a "virtual_server 109.247.115.97 53". So, is there
any way to only run the virtual_server on the machine that has the
vrrp_instance DNS_LAB_VIP active ?
-jf
------------------------------------------------------------------------------
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees