Issue with check mssql server

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
user1234
Posts: 15
Joined: Wed May 16, 2018 1:55 am

Issue with check mssql server

Post by user1234 »

Hello.
I've added by config wizard ms sql server.
Windows server 2019, sql server 2017.
Followed by https://assets.nagios.com/downloads/nag ... ios-XI.pdf

But i have error on every service.
(only host ping are online)
I tried to disable firewall also.
SQL server is without instance name.
Local sql account nagios with permission was created.
(No output on stdout) stderr: /bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Issue with check mssql server

Post by lmiltchev »

Can you show us the actual command run from the command line, along with the output of it? Obfuscate sensitive data. Thank you!
Be sure to check out our Knowledgebase for helpful articles and solutions!
user1234
Posts: 15
Joined: Wed May 16, 2018 1:55 am

Re: Issue with check mssql server

Post by user1234 »

Its not command issue, as same command working fine for other sql server.

Code: Select all

check_xi_mssql_server!-U 'login' -P 'pass' -p 1433 --locktimeouts --warning 20 --critical 30
Only differencies which i see that server which is not working has not custom instance name.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Issue with check mssql server

Post by lmiltchev »

Only differencies which i see that server which is not working has not custom instance name.
Do you have special characters in the password, e.g. "!"? This can cause the same issue.
Be sure to check out our Knowledgebase for helpful articles and solutions!
user1234
Posts: 15
Joined: Wed May 16, 2018 1:55 am

Re: Issue with check mssql server

Post by user1234 »

Thanks.
Yes, that was issue, special char.
I removed them and started working.
But its still some security policy issue with password without special char :cry:
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Issue with check mssql server

Post by scottwilkerson »

user1234 wrote:Thanks.
Yes, that was issue, special char.
I removed them and started working.
But its still some security policy issue with password without special char :cry:
You can use almost all special chars, but they may need to be escaped.

The ! is more complicated in nagios commands as it is argument separator in the command line.
https://support.nagios.com/kb/article.php?id=580
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked