===== SQL Server Plugin (Suse) ===== **Nagios plugin for SQL Server Access - check_mssql_health** Web site: http://labs.consol.de/lang/en/nagios/check_mssql_health/ ===== Prerequisites ===== *DBD::Sybase - DBI Perl's Database Interface (libdbd-sybase-perl) *FreeTDS - Connector for SQL Server e Sybase === DBD::Sybase - DBI Perl's Database Interface === DBD::Sybase it's a DB interface library for Perl. It's used by Perl script, like check_mssql_health. \\ Web site: [[http://rpm.pbone.net/index.php3?stat=3&limit=1&srodzaj=1&dl=40&search=perl-dbd-sybase|perl-DBD-Sybase]]. === FreeTDS - Connector for SQL Server and Sybase === FreeTDS (http://www.freetds.org/) requires an entry in config file (/usr/local/etc///freetds.conf//) for any SQL host to which you will have to access. \\ Every host must be defined as follow: [MY_HOST] host = my_host.silverice.it port = 1433 tds version = 8.0 The host name in square bracket [//MY_HOST//] must be the same used in check_mssql_health service definition in Nagios configuration file: define service{ use silverice-service host_name MY_HOST service_description Compass Replicator Queue Items Count - COMPASS_PRO_2514 check_command check_mssql_health! --name "SELECT count(*) AS Count FROM Compass_Pro_2514.dbo.REPLICATORQ WHERE FINALLOCATION = 'ABU'" -name2 "Items in Compass Replicator Queue" --warning 2000 --critical 2500 --username 'my_user' --password my_password --mode sql --encode } ===== Installation ===== -[[http://labs.consol.de/lang/en/nagios/check_mssql_health/|donwload the tarball]] in **''/download''** (for example) -goto in download folder: **''cd /download''** -extract the content: **''tar xzf check_mssql_health-//versione//.tar.gz''** -go to the extracted files directory: **''cd check_mssql_health-//version//''** -configure the package for the host system: **''./configure''** -compile the package: **''make''** -install the package: **''make install''**