MSSQL Server Wizard
Posted: Wed Jan 23, 2013 4:17 pm
Nagios version = 2012R1.2
I have a SQL 2005 server that I would like to pull performance info from. I created a SQL user for the MSSQL Server wizard and originally did not give it any rights. I configured the MSSQL Server wizard and added our DB server. On every metric we get CRITICAL: Unable to access SQL Server.
I went to the nagios server and ran:
/usr/local/nagios/libexec/check_mssql_server.py -H SQL-SERVER -U USERNAME -P PASSWORD --bufferhitratio
Result is: CRITICAL:Can access server but cannot query.
I tried to give the user different permissions to the master DB but it would return the same results.
I tried the same command with the sysadmin role granted with no access to the master DB and it worked.
/usr/local/nagios/libexec/check_mssql_server.py -H SQL-SERVER -U USERNAME -P PASSWORD --bufferhitratio
Result is: OK:Lazy Writes / Sec is 0.0|Lazy_Writes_/_Sec=0.0;;;;
The problem is that I cant leave the sysadmin role granted. So what permissions does the SQL user need to pull performance metrics from SQL 2005?
I have a SQL 2005 server that I would like to pull performance info from. I created a SQL user for the MSSQL Server wizard and originally did not give it any rights. I configured the MSSQL Server wizard and added our DB server. On every metric we get CRITICAL: Unable to access SQL Server.
I went to the nagios server and ran:
/usr/local/nagios/libexec/check_mssql_server.py -H SQL-SERVER -U USERNAME -P PASSWORD --bufferhitratio
Result is: CRITICAL:Can access server but cannot query.
I tried to give the user different permissions to the master DB but it would return the same results.
I tried the same command with the sysadmin role granted with no access to the master DB and it worked.
/usr/local/nagios/libexec/check_mssql_server.py -H SQL-SERVER -U USERNAME -P PASSWORD --bufferhitratio
Result is: OK:Lazy Writes / Sec is 0.0|Lazy_Writes_/_Sec=0.0;;;;
The problem is that I cant leave the sysadmin role granted. So what permissions does the SQL user need to pull performance metrics from SQL 2005?