Merge "Fixed VRRP nopreempt option"
This commit is contained in:
commit
47b8c360e9
@ -123,7 +123,6 @@ class KeepalivedJinjaTemplater:
|
|||||||
peers_ips.append(amp.vrrp_ip)
|
peers_ips.append(amp.vrrp_ip)
|
||||||
return self.get_template(self.keepalived_template).render(
|
return self.get_template(self.keepalived_template).render(
|
||||||
{'vrrp_group_name': loadbalancer.vrrp_group.vrrp_group_name,
|
{'vrrp_group_name': loadbalancer.vrrp_group.vrrp_group_name,
|
||||||
'amp_role': amphora.role,
|
|
||||||
'amp_intf': amphora.vrrp_interface,
|
'amp_intf': amphora.vrrp_interface,
|
||||||
'amp_vrrp_id': amphora.vrrp_id,
|
'amp_vrrp_id': amphora.vrrp_id,
|
||||||
'amp_priority': amphora.vrrp_priority,
|
'amp_priority': amphora.vrrp_priority,
|
||||||
|
@ -21,7 +21,6 @@ vrrp_script check_script {
|
|||||||
}
|
}
|
||||||
|
|
||||||
vrrp_instance {{ vrrp_group_name }} {
|
vrrp_instance {{ vrrp_group_name }} {
|
||||||
state {{ amp_role }}
|
|
||||||
interface {{ amp_intf }}
|
interface {{ amp_intf }}
|
||||||
virtual_router_id {{ amp_vrrp_id }}
|
virtual_router_id {{ amp_vrrp_id }}
|
||||||
priority {{ amp_priority }}
|
priority {{ amp_priority }}
|
||||||
|
@ -71,7 +71,6 @@ class TestVRRPRestDriver(base.TestCase):
|
|||||||
"}\n"
|
"}\n"
|
||||||
"\n"
|
"\n"
|
||||||
"vrrp_instance TESTGROUP {\n"
|
"vrrp_instance TESTGROUP {\n"
|
||||||
" state MASTER\n"
|
|
||||||
" interface eth1\n"
|
" interface eth1\n"
|
||||||
" virtual_router_id 1\n"
|
" virtual_router_id 1\n"
|
||||||
" priority 100\n"
|
" priority 100\n"
|
||||||
@ -124,7 +123,6 @@ class TestVRRPRestDriver(base.TestCase):
|
|||||||
"}\n"
|
"}\n"
|
||||||
"\n"
|
"\n"
|
||||||
"vrrp_instance TESTGROUP {\n"
|
"vrrp_instance TESTGROUP {\n"
|
||||||
" state MASTER\n"
|
|
||||||
" interface eth1\n"
|
" interface eth1\n"
|
||||||
" virtual_router_id 1\n"
|
" virtual_router_id 1\n"
|
||||||
" priority 100\n"
|
" priority 100\n"
|
||||||
@ -170,7 +168,6 @@ class TestVRRPRestDriver(base.TestCase):
|
|||||||
"}\n"
|
"}\n"
|
||||||
"\n"
|
"\n"
|
||||||
"vrrp_instance TESTGROUP {\n"
|
"vrrp_instance TESTGROUP {\n"
|
||||||
" state MASTER\n"
|
|
||||||
" interface eth1\n"
|
" interface eth1\n"
|
||||||
" virtual_router_id 1\n"
|
" virtual_router_id 1\n"
|
||||||
" priority 100\n"
|
" priority 100\n"
|
||||||
@ -220,7 +217,6 @@ class TestVRRPRestDriver(base.TestCase):
|
|||||||
"}\n"
|
"}\n"
|
||||||
"\n"
|
"\n"
|
||||||
"vrrp_instance TESTGROUP {\n"
|
"vrrp_instance TESTGROUP {\n"
|
||||||
" state MASTER\n"
|
|
||||||
" interface eth1\n"
|
" interface eth1\n"
|
||||||
" virtual_router_id 1\n"
|
" virtual_router_id 1\n"
|
||||||
" priority 100\n"
|
" priority 100\n"
|
||||||
|
@ -0,0 +1,8 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
Fixed a bug with the `nopreempt` option in keepalived. The option didn't
|
||||||
|
work properly because the default role of the `MASTER` amphora was set.
|
||||||
|
Removing the default roles from the configuration files fixed that issue.
|
||||||
|
Now after a failover, the newly created amphora doesn't preempt the
|
||||||
|
`MASTER` role from the other amphora.
|
Loading…
x
Reference in New Issue
Block a user