587943
From 240b9ec01e6a6e6554f0ae13d759c01339835a40 Mon Sep 17 00:00:00 2001
587943
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
587943
Date: Wed, 27 Jan 2021 10:10:03 +0100
587943
Subject: [PATCH] Feature: cibsecret: use crmadmin -N (which also lists guest
587943
 and remote nodes) to get nodes to sync to
587943
587943
---
587943
 tools/cibsecret.in | 4 ++--
587943
 1 file changed, 2 insertions(+), 2 deletions(-)
587943
587943
diff --git a/tools/cibsecret.in b/tools/cibsecret.in
587943
index 8923a70..6326bf0 100644
587943
--- a/tools/cibsecret.in
587943
+++ b/tools/cibsecret.in
587943
@@ -182,9 +182,9 @@ get_live_peers() {
587943
     [ $? -eq 0 ] || fatal $CRM_EX_UNAVAILABLE "couldn't get local node name"
587943
 
587943
     # Get a list of all other cluster nodes
587943
-    GLP_ALL_PEERS="$(crm_node -l)"
587943
+    GLP_ALL_PEERS="$(crmadmin -N -q)"
587943
     [ $? -eq 0 ] || fatal $CRM_EX_UNAVAILABLE "couldn't determine cluster nodes"
587943
-    GLP_ALL_PEERS="$(echo "$GLP_ALL_PEERS" | awk '{print $2}' | grep -v "^${GLP_LOCAL_NODE}$")"
587943
+    GLP_ALL_PEERS="$(echo "$GLP_ALL_PEERS" | grep -v "^${GLP_LOCAL_NODE}$")"
587943
 
587943
     # Make a list of those that respond to pings
587943
     if [ "$(id -u)" = "0" ] && which fping >/dev/null 2>&1; then
587943
-- 
587943
1.8.3.1
587943