Error message when check sql servers with Nagios Client Inst

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Error message when check sql servers with Nagios Client Inst

Post by Kxfrancois »

Hi,

I am new to Nagios. We were handed this platform from our predecessor. When I look at the sql Servers, they all have the same error messages.

Unknown
SQL Server message 18456, severity 14, state 1, line 1:
Login failed for user 'SRV-Nagios-Monitor'.
DB-Lib error message 18456, severity 14:
General SQL Server error: Check messages from the SQL Server
DB-Lib error message 20002, severity 9:
Adaptive Server connection failed

any ideas?

Thanks,
Kerwin
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Error message when check sql servers with Nagios Client

Post by scottwilkerson »

Are we sure the user SRV-Nagios-Monitor is still valid for the server? Have we verified the credentials for the user?
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Re: Error message when check sql servers with Nagios Client

Post by Kxfrancois »

Yes I have. I have used those credentials to logon onto the server.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Error message when check sql servers with Nagios Client

Post by scottwilkerson »

Is this a domain user?

Does the user have rights to login to MSSQL?

Can you show the whole command nagios is running when giving these results?
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Re: Error message when check sql servers with Nagios Client

Post by Kxfrancois »

Command View: $USER1$/check_mssql_server.py -H $HOSTADDRESS$ $ARG1$
$ARG1$: -U 'SRV-Nagios-Monitor' -P 'correct_PW' -p 1433 --pagereads --warning 20 --critical 30

I get this as a result:

[[email protected] ~]$ /usr/local/nagios/libexec/check_mssql_server.py -H 172.28.48.24 -U 'SRV-Nagios-Monitor' -P 'correct_PW' -p 1433 --pagereads --warning 20 --critical 30
SQL Server message 18456, severity 14, state 1, line 1:
Login failed for user 'SRV-Nagios-Monitor'.
DB-Lib error message 18456, severity 14:
General SQL Server error: Check messages from the SQL Server
DB-Lib error message 20002, severity 9:
Adaptive Server connection failed
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Error message when check sql servers with Nagios Client

Post by scottwilkerson »

scottwilkerson wrote:Is this a domain user?

Does the user have rights to login to MSSQL?
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Re: Error message when check sql servers with Nagios Client

Post by Kxfrancois »

Sorry about that. Yes this is a domain user and this user has rights to login to SQL.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Error message when check sql servers with Nagios Client

Post by scottwilkerson »

for a domain user you will need to add toh domain to the username field

Code: Select all

/usr/local/nagios/libexec/check_mssql_server.py -H 172.28.48.24 -U 'DOMAIN\SRV-Nagios-Monitor' -P 'correct_PW' -p 1433 --pagereads --warning 20 --critical 30
See page 11 here:
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Re: Error message when check sql servers with Nagios Client

Post by Kxfrancois »

Same result

[[email protected] ~]$ /usr/local/nagios/libexec/check_mssql_server.py -H 172.28.48.24 -U 'firstlightpower\SRV-Nagios-Monitor' -P 'correct_PW' -p 1433 --averagewait --warning 1500 --critical 2000
SQL Server message 18456, severity 14, state 1, line 1:
Login failed for user ''.
DB-Lib error message 18456, severity 14:
General SQL Server error: Check messages from the SQL Server
DB-Lib error message 20002, severity 9:
Adaptive Server connection failed
Kxfrancois
Posts: 48
Joined: Mon Nov 19, 2018 9:38 am

Re: Error message when check sql servers with Nagios Client

Post by Kxfrancois »

I ran through the document you sent me and I am still getting the same error message:
Locked