Doing a MSSQL Query

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
Michael.at.NIU
Posts: 6
Joined: Wed May 15, 2013 11:09 am

Doing a MSSQL Query

Post by Michael.at.NIU »

When you send out an SQL query, you have --username <name> in the command line. If you have users from active directory they are <domain>\<name>. Only when I try to send <domain>\<name>, nagios says that \ is an invalid character. I checked other help files and it looked like maybe i had to send it as --username <name>@<domain>, but then nagios claims @ is an invalid character.

We have multiple databases, and having one Active Directory account set up to handle these queriesl works better than entering every database and adding a local user. However, if there's no way I can tell SQL that i'm logging in with an Active Directory user, because Nagios can't submit that kind of username, then i'm forced to use a local account.

Is there a way to set the command line to submit an <domain>\<name>?
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Doing a MSSQL Query

Post by abrist »

You cannot use a domain user to check an mssql db. It must be a pure database user as it is connecting directly to the db socket, not through a domain controller.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Michael.at.NIU
Posts: 6
Joined: Wed May 15, 2013 11:09 am

Re: Doing a MSSQL Query

Post by Michael.at.NIU »

Thank you.
Locked