Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sql-runtime does not work on v 2.6.4.10 #28

Open
fledorze opened this issue May 11, 2017 · 1 comment
Open

sql-runtime does not work on v 2.6.4.10 #28

fledorze opened this issue May 11, 2017 · 1 comment

Comments

@fledorze
Copy link

**We just downloaded last version from Console Labs site. The other modes we use seem to work fine except --mode sql-runtime, which gives the output below.
It always generate 0s as sql_runtime in perfdata.

The former old version 1.5.19.3 gives a different output, see below. But the runtime seems to be correct.**

What is wrong ?
Thx

./check_mssql_health --server INSTANCE --username User --password Password --mode sql-runtime -t 90 -v -v -v
Thu May 11 17:15:14 2017: SQL:
SELECT @@Version
ARGS:
$VAR1 = [];

Thu May 11 17:15:14 2017: RESULT:
$VAR1 = [
'Microsoft SQL Server 2008 R2 (SP2) - 10.50.4000.0 (X64)
Jun 28 2012 08:36:30
Copyright (c) Microsoft Corporation
Standard Edition (64-bit) on Windows NT 6.1 (Build 7601: Service Pack 1) (Hypervisor)
'
];

Thu May 11 17:15:14 2017: AUTOLOAD Classes::MSSQL::DBI::override_opt

Thu May 11 17:15:14 2017: AUTOLOAD Classes::MSSQL::DBI::check_messages

Thu May 11 17:15:14 2017: SQL:
SELECT SYSTEM_USER
ARGS:
$VAR1 = [];

Thu May 11 17:15:14 2017: RESULT:
$VAR1 = [
'GOPSAMonitoring'
];

Thu May 11 17:15:14 2017: SQL:
SELECT @@SERVICENAME
ARGS:
$VAR1 = [];

Thu May 11 17:15:14 2017: RESULT:
$VAR1 = [
'RIMSES_PROD'
];

Thu May 11 17:15:14 2017: SQL:
SELECT CAST(COALESCE(SERVERPROPERTY('IsHadrEnabled'), 0) as int)
ARGS:
$VAR1 = [];

Thu May 11 17:15:14 2017: RESULT:
$VAR1 = [
0
];

Thu May 11 17:15:14 2017: SQL:

ARGS:
$VAR1 = [];

Thu May 11 17:15:14 2017: RESULT:
$VAR1 = [];

Thu May 11 17:15:14 2017: stderr Use of uninitialized value $sql in sprintf at ./check_mssql_health line 6382.
Use of uninitialized value in subroutine entry at /usr/local/lib64/perl5/DBD/Sybase.pm line 138.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health line 6390.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health line 6390.

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::check_messages

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::SUPER::set_thresholds

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::check_thresholds

Use of uninitialized value in sprintf at ./check_mssql_health line 2804.
Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::add_perfdata

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::check_messages

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::check_messages

Thu May 11 17:15:14 2017: AUTOLOAD Monitoring::GLPlugin::DB::nagios_exit

WARNING - Use of uninitialized value $sql in sprintf at ./check_mssql_health line 6382.
Use of uninitialized value in subroutine entry at /usr/local/lib64/perl5/DBD/Sybase.pm line 138.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health line 6390.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health line 6390.

, 0.00 seconds to execute
| 'sql_runtime'=0.00s;1;5;;
Thu May 11 17:15:14 2017: try to clean up command and result files_

./check_mssql_health-1.5.19.3 --server DBSRV-000045 --username GOPSAMonitoring --password 'InspiretheNext2015!' --mode sql-runtime -t 90 -v -v -v
Thu May 11 17:21:42 2017: SQL:
SELECT @@Version
ARGS:
$VAR1 = [];

Thu May 11 17:21:42 2017: RESULT:
$VAR1 = [
'Microsoft SQL Server 2008 R2 (SP2) - 10.50.4000.0 (X64)
Jun 28 2012 08:36:30
Copyright (c) Microsoft Corporation
Standard Edition (64-bit) on Windows NT 6.1 (Build 7601: Service Pack 1) (Hypervisor)
'
];

Thu May 11 17:21:42 2017: SQL:
SELECT SYSTEM_USER
ARGS:
$VAR1 = [];

Thu May 11 17:21:42 2017: RESULT:
$VAR1 = [
'GOPSAMonitoring'
];

Thu May 11 17:21:42 2017: SQL:
SELECT @@SERVICENAME
ARGS:
$VAR1 = [];

Thu May 11 17:21:42 2017: RESULT:
$VAR1 = [
'RIMSES_PROD'
];

Thu May 11 17:21:42 2017: SQL:

ARGS:
$VAR1 = [];

Thu May 11 17:21:42 2017: RESULT:
$VAR1 = [];

Thu May 11 17:21:42 2017: stderr Use of uninitialized value $sql in sprintf at ./check_mssql_health-1.5.19.3 line 3098.
Use of uninitialized value in subroutine entry at /usr/local/lib64/perl5/DBD/Sybase.pm line 138.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health-1.5.19.3 line 3106.
Use of uninitialized value $sql in pattern match (m//) at ./check_mssql_health-1.5.19.3 line 3106.
Use of uninitialized value $params{"selectname"} in sprintf at ./check_mssql_health-1.5.19.3 line 2206.

OK - 0.00 seconds to execute | sql_runtime=0.0003;1;5

@lausser
Copy link
Owner

lausser commented May 12, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants