Post to opensaf devel list
-------- Forwarded Message -------- Subject: [PATCH 1 of 1] AMFD: Prioritize to failover absent assignment [#2161] Date: Thu, 3 Nov 2016 14:34:14 +1100 From: minh chau <[email protected]> To: Hans Nordebäck <[email protected]>, Nagendra Kumar <[email protected]>, Praveen Malviya <[email protected]>, Gary Lee ([email protected]) <[email protected]>, Long Nguyen <[email protected]>, [email protected] osaf/services/saf/amf/amfd/cluster.cc | 12 +++++------- 1 files changed, 5 insertions(+), 7 deletions(-) In non-headless scenario, if there is a SU becoming OUT-OF-SERVICE due to node reboot, the situation should be handled in node_fail_su_oper, where the assignment of OUT-OF-SERVICE SU will be removed. In other words, the susi_success_su_oper is not supposed to handle an OUT-OF-SERVICE SU but still having assignment. When susi_success_su_oper() is called, SU having assignment must be IN-SERVICE. In scenario of headless recovery, which currently outweights pending assignment than absent assignment, that would cause susi_success_su_oper() encounter an OUT-OF-SERVICE SU but still has assignment (even absent assignment though). The result eventually is that AMFD will generate unexpected assignment messages. A solution is that AMFD can revert the order of headless recovery, which prioritizes to failover absent assignment first. This change should also be working, because it has already been supported in non-headless, where a node restarts while assignment on another node is still in progress. diff --git a/osaf/services/saf/amf/amfd/cluster.cc b/osaf/services/saf/amf/amfd/cluster.cc --- a/osaf/services/saf/amf/amfd/cluster.cc +++ b/osaf/services/saf/amf/amfd/cluster.cc @@ -98,13 +98,11 @@ void avd_cluster_tmr_init_evh(AVD_CL_CB continue; } - if (i_sg->any_assignment_in_progress() == false) { - if (i_sg->any_assignment_absent() == false) { - i_sg->set_fsm_state(AVD_SG_FSM_STABLE); - } else { - // failover with ABSENT SUSI, which had already been removed during headless - i_sg->failover_absent_assignment(); - } + if (i_sg->any_assignment_absent()) { + // failover with ABSENT SUSI, which had already been removed during headless + i_sg->failover_absent_assignment(); + } else if (i_sg->any_assignment_in_progress() == false) { + i_sg->set_fsm_state(AVD_SG_FSM_STABLE); } if (i_sg->sg_fsm_state == AVD_SG_FSM_STABLE) ------------------------------------------------------------------------------ Developer Access Program for Intel Xeon Phi Processors Access to Intel Xeon Phi processor-based developer platforms. With one year of Intel Parallel Studio XE. Training and support from Colfax. Order your platform today. http://sdm.link/xeonphi _______________________________________________ Opensaf-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opensaf-devel
