From f774b44b47dd648fb4d21519d1afd03b35b277f3 Mon Sep 17 00:00:00 2001 From: Michael Salsone Date: Thu, 7 Dec 2017 10:27:20 -0600 Subject: [PATCH] Update check_ipa_replication Fix this slice so it gets the correct value. --- check_ipa/check_ipa_replication | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/check_ipa/check_ipa_replication b/check_ipa/check_ipa_replication index bfedadc..d84ecf9 100644 --- a/check_ipa/check_ipa_replication +++ b/check_ipa/check_ipa_replication @@ -46,9 +46,9 @@ except Exception, e: # Loop through replication agreements for rhost in replication: plugin.add_summary("Replica %s Status: %s" % (rhost[1]['nsDS5ReplicaHost'][0], rhost[1]['nsds5replicaLastUpdateStatus'][0])) - if rhost[1]['nsds5replicaLastUpdateStatus'][0][:2] == "0 ": + if rhost[1]['nsds5replicaLastUpdateStatus'][0][7:8] == "0": plugin.status(ok) - elif rhost[1]['nsds5replicaLastUpdateStatus'][0][:2] == "1 ": + elif rhost[1]['nsds5replicaLastUpdateStatus'][0][7:8] == "1": # Busy Replica is not an error, its "unknown" (but its "ok" for now) plugin.status(ok) else: