Search
j0ke.net Open Build Service
>
Projects
>
ha
>
keepalived-ipv6
> keepalived-priority.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File keepalived-priority.patch of Package keepalived-ipv6 (Revision 22)
Currently displaying revision
22
,
show latest
From 0685d312f8160b776b299e31224b83c63f42abfd Mon Sep 17 00:00:00 2001 From: Vincent Bernat <bernat@luffy.cx> Date: Mon, 30 Jan 2012 13:51:28 +0000 Subject: Fix priority not changing on reload In 1.2.2 if a user changes the priority assigned to a vrrp-group and reloads the configuration, the old priority will persist. This is caused by saving the effective_priority in reset_vrrp_state. While this makes sense for the case where a weighted interface or script is used, it prevents to change the priority when sync groups are used (no thread with vrrp_update_priority() is running in this case). Since sync groups do not allow the use of weighted interfaces or scripts, the effective priority is not copied over when they are used. Original patch credit goes to John Southworth (Vyatta). --- diff --git a/keepalived/vrrp/vrrp.c b/keepalived/vrrp/vrrp.c index b347737..158ed3e 100644 --- a/keepalived/vrrp/vrrp.c +++ b/keepalived/vrrp/vrrp.c @@ -1196,7 +1196,8 @@ reset_vrrp_state(vrrp_rt * old_vrrp) vrrp->state = old_vrrp->state; vrrp->init_state = old_vrrp->state; vrrp->wantstate = old_vrrp->state; - vrrp->effective_priority = old_vrrp->effective_priority; + if (!old_vrrp->sync) + vrrp->effective_priority = old_vrrp->effective_priority; memcpy(vrrp->ipsecah_counter, old_vrrp->ipsecah_counter, sizeof(seq_counter)); #ifdef _HAVE_IPVS_SYNCD_ -- cgit v0.8.3.4