From 8d9b7fdd2b146dc8a1578d6ee23c79aa3116f87e Mon Sep 17 00:00:00 2001 From: Chinasubbareddy Mallavarapu Date: Tue, 21 Apr 2020 11:47:35 -0500 Subject: [PATCH] [ceph-mon-check] fix the command to connect correct ceph cluster This is to fix the command to connect to the cluster name instead of namesapce. Change-Id: I8b8f7c10d7667245a8f6cb02fb5b69dd122099e5 --- ceph-mon/templates/bin/moncheck/_reap-zombies.py.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ceph-mon/templates/bin/moncheck/_reap-zombies.py.tpl b/ceph-mon/templates/bin/moncheck/_reap-zombies.py.tpl index cb72401d72..f33487f9cd 100644 --- a/ceph-mon/templates/bin/moncheck/_reap-zombies.py.tpl +++ b/ceph-mon/templates/bin/moncheck/_reap-zombies.py.tpl @@ -11,7 +11,7 @@ if int(os.getenv('K8S_HOST_NETWORK', 0)) > 0: else: kubectl_command = 'kubectl get pods --namespace=${NAMESPACE} -l component=mon,application=ceph -o template --template="{ {{"{{"}}range \$i, \$v := .items{{"}}"}} {{"{{"}} if \$i{{"}}"}} , {{"{{"}} end {{"}}"}} \\"{{"{{"}}\$v.metadata.name{{"}}"}}\\": \\"{{"{{"}}\$v.status.podIP{{"}}"}}\\" {{"{{"}}end{{"}}"}} }"' -monmap_command = "ceph --cluster=${NAMESPACE} mon getmap > /tmp/monmap && monmaptool -f /tmp/monmap --print" +monmap_command = "ceph --cluster=${CLUSTER} mon getmap > /tmp/monmap && monmaptool -f /tmp/monmap --print" def extract_mons_from_monmap():