I understand some work was done on embedded characters but now when I get rid of double slash and double dollars etc the test feature works in NagiosXI UI but when submitted they dont work, this is pretty frustrating especially as I asked about this before we upgraded, why is this not consistent across testing and when config applied?
For example
-l "MSSQL\\$$RHMHAPSQL" -d SHOWALL
The above worked in the previous 2012 but failed when I upgraded, changed this to
-l "MSSQL$RHMHAPSQL" -d SHOWALL
The above works fine in test
COMMAND: /usr/local/nagios/libexec/check_nt -H 10.168.250.241 -s "" -t 20 -p 12489 -v SERVICESTATE -l "MSSQL\$RHMHAPSQL" -d SHOWALL
OUTPUT: MSSQL$RHMHAPSQL: Stopped
When I apply this config and look at the service (even after a scheduled check etc)
SQL Server - HAP SQL Instance
This service has commentsThis service is flappingThis service problem has been acknowledged
Critical 9m 45s 5/5 2014-07-25 00:49:27 MSSQL: Not found
As you can see the $RHMHAPSQL bit has been truncated completely
Command line parameters no longer working since upgrade to 2
-
JulianFDRacing
- Posts: 51
- Joined: Tue Oct 16, 2012 9:45 am
Re: Command line parameters no longer working since upgrade
Testing from within CCM works great for many checks, but not for all of them. It's not a substitute for testing from the CLI. It may fail with some database checks because of the escaping issues.
I would recommend testing your check from the command line, then modifying the check accordingly either in the CCM or under the "Configure Service" page (Service Detail->...->Configure->Re-configure this service).
I would recommend testing your check from the command line, then modifying the check accordingly either in the CCM or under the "Configure Service" page (Service Detail->...->Configure->Re-configure this service).
Be sure to check out our Knowledgebase for helpful articles and solutions!