File pacemaker#3409-0007-Log-scheduler-log-unknown-nodes-in-location-constrai.patch of Package pacemaker.34782

From 723be0bc814a66e27aea34d86f1dc7eaebc90cee Mon Sep 17 00:00:00 2001
From: Ken Gaillot <kgaillot@redhat.com>
Date: Wed, 20 Mar 2024 15:33:24 -0500
Subject: [PATCH 7/7] Log: scheduler: log unknown nodes in location constraints

Fixes T784 (CLBZ#5415)
---
 lib/pacemaker/pcmk_sched_constraints.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Index: pacemaker-2.0.5+20201202.ba59be712/lib/pacemaker/pcmk_sched_constraints.c
===================================================================
--- pacemaker-2.0.5+20201202.ba59be712.orig/lib/pacemaker/pcmk_sched_constraints.c
+++ pacemaker-2.0.5+20201202.ba59be712/lib/pacemaker/pcmk_sched_constraints.c
@@ -814,7 +814,10 @@ unpack_rsc_location(xmlNode * xml_obj, p
         int score_i = char2score(score);
         pe_node_t *match = pe_find_node(data_set->nodes, node);
 
-        if (!match) {
+        if (match == NULL) {
+            crm_info("Ignoring location constraint %s "
+                     "because '%s' is not a known node",
+                     id ? id : "without ID", node);
             return FALSE;
         }
         location = rsc2node_new(id, rsc_lh, score_i, discovery, match, data_set);
openSUSE Build Service is sponsored by