Issues with MS SQL checks
Posted: Tue Oct 15, 2013 12:59 am
Hi,
I'm having a strange problem with the results of an SQL service check which does not seem to be consistent with the rest of the SQL checks in the system.
I have checked 2 different service checks from the command line to troubleshoot but no issue:
[root@aunagiosxi libexec]# ./check_mssql -H X --port 1433 --username X --password "X" --database X --query "EXECUTE usp_Alert_ConsignmentDataNotPopulating" --result 0
OK: Query results matched, query duration=1.943026 seconds.
[root@aunagiosxi libexec]# ./check_mssql -H X --port X --username X --password "X" --database LDW_Staging --query "EXECUTE usp_Alert_JobEventDataNotPopulating" --result 0
OK: Query results matched, query duration=0.000855 seconds.
Yet when I run from Nagios console I get 2 different results:
MSSQL Query - Check TMS to AUVIS Sync
This service is flapping
Warning 5m 45s 5/5 15/10/2013 16:50:13
WARNING: Query results matched, query duration=2.007195 seconds.
MSSQL Query - Check TMS to LDW Sync
Ok 10d 16h 3m 52s 1/5 15/10/2013 16:50:29
OK: Query results matched, query duration=0.000984 seconds.
Some time ago I updated the code within the script which caused a bug in the results translation to OK/Warning/Alert. But I now only get an issue with this one particular result. See below forum post:
http://support.nagios.com/forum/viewtop ... 16&t=10266
Do you have any idea what I can do to rectify/further analyse this please?
I'm having a strange problem with the results of an SQL service check which does not seem to be consistent with the rest of the SQL checks in the system.
I have checked 2 different service checks from the command line to troubleshoot but no issue:
[root@aunagiosxi libexec]# ./check_mssql -H X --port 1433 --username X --password "X" --database X --query "EXECUTE usp_Alert_ConsignmentDataNotPopulating" --result 0
OK: Query results matched, query duration=1.943026 seconds.
[root@aunagiosxi libexec]# ./check_mssql -H X --port X --username X --password "X" --database LDW_Staging --query "EXECUTE usp_Alert_JobEventDataNotPopulating" --result 0
OK: Query results matched, query duration=0.000855 seconds.
Yet when I run from Nagios console I get 2 different results:
MSSQL Query - Check TMS to AUVIS Sync
This service is flapping
Warning 5m 45s 5/5 15/10/2013 16:50:13
WARNING: Query results matched, query duration=2.007195 seconds.
MSSQL Query - Check TMS to LDW Sync
Ok 10d 16h 3m 52s 1/5 15/10/2013 16:50:29
OK: Query results matched, query duration=0.000984 seconds.
Some time ago I updated the code within the script which caused a bug in the results translation to OK/Warning/Alert. But I now only get an issue with this one particular result. See below forum post:
http://support.nagios.com/forum/viewtop ... 16&t=10266
Do you have any idea what I can do to rectify/further analyse this please?