[monitoring-plugins] check_mssql.pl: switched alarm timeout

Oliver Skibbe git at monitoring-plugins.org
Sat Nov 19 16:40:11 CET 2016


    Module: monitoring-plugins
    Branch: master
    Commit: 223c59466140d9837233efe79545792e859cb9fa
    Author: Bernd Apfel <wopfel at gmail.com>
 Committer: Oliver Skibbe <oliskibbe at gmail.com>
      Date: Thu Oct 15 11:20:20 2015 +0200
       URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=223c594

check_mssql.pl: switched alarm timeout

  - alarm() now uses -t option
    contributed by Bernd Arnold (wopfel at gmail.com)

    closes #991

---

 plugins-scripts/check_mssql.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/plugins-scripts/check_mssql.pl b/plugins-scripts/check_mssql.pl
index fb3952d..bf3a651 100755
--- a/plugins-scripts/check_mssql.pl
+++ b/plugins-scripts/check_mssql.pl
@@ -54,7 +54,7 @@ $SIG{'ALRM'} = sub {
      print ("SQL UNKNOWN: ERROR connection $server (alarm timeout)\n");
      exit $ERRORS{"UNKNOWN"};
 };
-alarm($TIMEOUT);
+alarm($timeout);
 
 unless ($dbh = DBI->connect("dbi:Sybase:server=".uc($server), "$username", "$password")) {
 	printf "SQL CRITICAL: Can't connect to mssql server $DBI::errstr\n";



More information about the Commits mailing list