[Nagiosplug-checkins] CVS: nagiosplug/plugins-scripts check_ntp.pl,1.19,1.20

Matthew Kent mattkent at users.sourceforge.net
Thu Nov 18 20:01:33 CET 2004


Update of /cvsroot/nagiosplug/nagiosplug/plugins-scripts
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7608

Modified Files:
	check_ntp.pl 
Log Message:
Fix incorrectly labelled units in output (1025905, Jason Martin)


Index: check_ntp.pl
===================================================================
RCS file: /cvsroot/nagiosplug/nagiosplug/plugins-scripts/check_ntp.pl,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** check_ntp.pl	14 Oct 2003 02:40:31 -0000	1.19
--- check_ntp.pl	19 Nov 2004 03:59:43 -0000	1.20
***************
*** 359,369 ****
  	if (abs($offset) > $ocrit) {
  		$state = $ERRORS{'CRITICAL'};
! 		$answer = "Offset $offset msec > +/- $ocrit sec\n";
  	} elsif (abs($offset) > $owarn) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset msec > +/- $owarn sec\n";
  	} elsif (( abs($offset) > $owarn) && $def_jitter ) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset msec > +/- $owarn sec, ntpq timed out\n";
  	} elsif ( $def_jitter ) {
  		$state = $ERRORS{'WARNING'};
--- 359,369 ----
  	if (abs($offset) > $ocrit) {
  		$state = $ERRORS{'CRITICAL'};
! 		$answer = "Offset $offset sec > +/- $ocrit sec\n";
  	} elsif (abs($offset) > $owarn) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset sec > +/- $owarn sec\n";
  	} elsif (( abs($offset) > $owarn) && $def_jitter ) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset sec > +/- $owarn sec, ntpq timed out\n";
  	} elsif ( $def_jitter ) {
  		$state = $ERRORS{'WARNING'};
***************
*** 379,383 ****
  	if (abs($offset) > $ocrit) {
  		$state = $ERRORS{'CRITICAL'};
! 		$answer = "Offset $offset msec > +/- $ocrit sec, jitter $jitter msec\n";
  	} elsif (abs($jitter) > $jcrit ) {
  		$state = $ERRORS{'CRITICAL'};
--- 379,383 ----
  	if (abs($offset) > $ocrit) {
  		$state = $ERRORS{'CRITICAL'};
! 		$answer = "Offset $offset sec > +/- $ocrit sec, jitter $jitter msec\n";
  	} elsif (abs($jitter) > $jcrit ) {
  		$state = $ERRORS{'CRITICAL'};
***************
*** 385,389 ****
  	} elsif (abs($offset) > $owarn) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset msec > +/- $owarn sec, jitter $jitter msec\n";
  	} elsif (abs($jitter) > $jwarn ) {
  		$state = $ERRORS{'WARNING'};
--- 385,389 ----
  	} elsif (abs($offset) > $owarn) {
  		$state = $ERRORS{'WARNING'};
! 		$answer = "Offset $offset sec > +/- $owarn sec, jitter $jitter msec\n";
  	} elsif (abs($jitter) > $jwarn ) {
  		$state = $ERRORS{'WARNING'};





More information about the Commits mailing list