Skip to content

Commit

Permalink
ntp-w32tm: Add missing WARN state
Browse files Browse the repository at this point in the history
  • Loading branch information
markuslf committed Sep 3, 2024
1 parent f3871ce commit d590981
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion check-plugins/ntp-w32tm/ntp-w32tm
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ from lib.globals import (STATE_CRIT, STATE_OK, # pylint: disable=C0413
STATE_UNKNOWN, STATE_WARN)

__author__ = 'Linuxfabrik GmbH, Zurich/Switzerland'
__version__ = '2024021501'
__version__ = '2024090201'

DESCRIPTION = '''This monitoring plugin runs `w32tm /query /status /verbose` (Windows)
to help diagnose problems with the time settings.'''
Expand Down Expand Up @@ -115,6 +115,7 @@ def main():
peer_used = stratum != 0
if not peer_used:
msg.append('No NTP server used {}'.format(lib.base.state2str(STATE_WARN)))
state = STATE_WARN
if stratum > 4:
msg.append('{} {}'.format(line, lib.base.state2str(STATE_WARN)))
state = STATE_WARN
Expand Down

0 comments on commit d590981

Please sign in to comment.