Blame SOURCES/076-quorum-loss.patch

139d2d
From 0b6890554a1928ec96cc22f71497d7874e72aa4f Mon Sep 17 00:00:00 2001
139d2d
From: Ken Gaillot <kgaillot@redhat.com>
139d2d
Date: Tue, 27 Jun 2017 12:27:32 -0500
139d2d
Subject: [PATCH] Fix: crmd: abort transition whenever we lose quorum
139d2d
139d2d
If a node drops us below quorum because it was unexpectedly lost, the peer
139d2d
update callback will abort the transition. If it was shut down cleanly while
139d2d
running resources, the CIB recovery results will abort the transition. However,
139d2d
if it was shut down cleanly while not running any resources (e.g. in standby
139d2d
mode), previously we would not trigger a new transition, and the remaining
139d2d
nodes would not stop their resources until the next recheck interval.
139d2d
---
139d2d
 crmd/membership.c | 8 ++++++++
139d2d
 1 file changed, 8 insertions(+)
139d2d
139d2d
diff --git a/crmd/membership.c b/crmd/membership.c
139d2d
index b292f23..c36dbed 100644
139d2d
--- a/crmd/membership.c
139d2d
+++ b/crmd/membership.c
139d2d
@@ -437,6 +437,14 @@ crm_update_quorum(gboolean quorum, gboolean force_update)
139d2d
         crm_debug("Updating quorum status to %s (call=%d)", quorum ? "true" : "false", call_id);
139d2d
         fsa_register_cib_callback(call_id, FALSE, NULL, cib_quorum_update_complete);
139d2d
         free_xml(update);
139d2d
+
139d2d
+        /* If a node not running any resources is cleanly shut down and drops us
139d2d
+         * below quorum, we won't necessarily abort the transition, so abort it
139d2d
+         * here to be safe.
139d2d
+         */
139d2d
+        if (quorum == FALSE) {
139d2d
+            abort_transition(INFINITY, tg_restart, "Quorum loss", NULL);
139d2d
+        }
139d2d
     }
139d2d
     fsa_has_quorum = quorum;
139d2d
 }
139d2d
-- 
139d2d
1.8.3.1
139d2d