b760035b15
- Resolves: rhbz2102292
48 lines
1.5 KiB
Diff
48 lines
1.5 KiB
Diff
From e5f80059c7f1c0ad3264dc2a2a61e64cded0fe0f Mon Sep 17 00:00:00 2001
|
|
From: Hideo Yamauchi <renayama19661014@ybb.ne.jp>
|
|
Date: Tue, 12 Jul 2022 14:45:55 +0900
|
|
Subject: [PATCH] High: scheduler: Resolves an issue where STONITH devices
|
|
cannot be registered.
|
|
|
|
---
|
|
lib/pacemaker/pcmk_sched_allocate.c | 10 ++++++++++
|
|
1 file changed, 10 insertions(+)
|
|
|
|
diff --git a/lib/pacemaker/pcmk_sched_allocate.c b/lib/pacemaker/pcmk_sched_allocate.c
|
|
index 85df6ace8..a7fe9c8d6 100644
|
|
--- a/lib/pacemaker/pcmk_sched_allocate.c
|
|
+++ b/lib/pacemaker/pcmk_sched_allocate.c
|
|
@@ -724,12 +724,18 @@ log_unrunnable_actions(pe_working_set_t *data_set)
|
|
static void
|
|
unpack_cib(xmlNode *cib, unsigned long long flags, pe_working_set_t *data_set)
|
|
{
|
|
+ const char* localhost_save = NULL;
|
|
+
|
|
if (pcmk_is_set(data_set->flags, pe_flag_have_status)) {
|
|
crm_trace("Reusing previously calculated cluster status");
|
|
pe__set_working_set_flags(data_set, flags);
|
|
return;
|
|
}
|
|
|
|
+ if (data_set->localhost) {
|
|
+ localhost_save = data_set->localhost;
|
|
+ }
|
|
+
|
|
CRM_ASSERT(cib != NULL);
|
|
crm_trace("Calculating cluster status");
|
|
|
|
@@ -740,6 +746,10 @@ unpack_cib(xmlNode *cib, unsigned long long flags, pe_working_set_t *data_set)
|
|
*/
|
|
set_working_set_defaults(data_set);
|
|
|
|
+ if (localhost_save) {
|
|
+ data_set->localhost = localhost_save;
|
|
+ }
|
|
+
|
|
pe__set_working_set_flags(data_set, flags);
|
|
data_set->input = cib;
|
|
cluster_status(data_set); // Sets pe_flag_have_status
|
|
--
|
|
2.31.1
|
|
|