1
0
mirror of https://github.com/opinkerfi/nagios-plugins.git synced 2024-12-22 09:03:54 +01:00

Added missing OK when things worked out

This commit is contained in:
Tomas Edwardsson 2013-04-26 10:36:23 +00:00
parent ebd64badf2
commit ff21dd3ec4

View File

@ -15,7 +15,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
import ldap
from pynag.Plugins import PluginHelper,critical, warning
from pynag.Plugins import PluginHelper, critical, warning, ok
plugin = PluginHelper()
@ -48,6 +48,8 @@ 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 ":
plugin.status(critical)
else
plugin.status(ok)
if not len(replication):
plugin.add_summary("Warning: No replicas found")