SQL Database Size monitoring with nsca.

Jason Payne jasonp at iland.com
Thu Sep 5 16:21:36 CEST 2002


Speaking of sql databases...I've used nsca to monitor a windows SQL Database
doing this.  Just fyi.

Added these into...

services.cfg:
define service {
host_name                      sql3
service_description            doortodoor DB Size
check_command                  check_nt_sqldbsize!90000!99000
use                            generic-service
max_check_attempts             3
normal_check_interval          5
retry_check_interval           1
check_period                   24x7
notification_interval          240
notification_period            24x7
notification_options           c,r
contact_groups                 windows-admins
}

checkcommands.cfg
define command{
        command_name    check_nt_sqldbsize
        command_line    $USER1$/check_nt -H $HOSTADDRESS$ -p 1248 -v
COUNTER -l "\\SQLServer:Databases(doortodoor)\\Data File(s) Size
(KB)","Doortodoor SQL DB size is %.2f %%" -w $ARG1$ -c $ARG2$
}

ran ./restartnagios.sh
Running configuration check...done
Stopping network monitor: nagios
Starting network monitor: nagios
  PID  TT  STAT      TIME COMMAND
64810  ??  Ss     0:00.03 /home/nagios/bin/nagios -d
/home/nagios/etc/nagios.cf

Ran fine, and..

 doortodoor DB Size
 OK 09-05-2002 09:23:56 0d 0h 9m 31s 1/3 Doortodoor SQL DB size is 86912.00
%

Whala.  I love nagios.

-Jason Payne



-------------------------------------------------------
This sf.net email is sponsored by: OSDN - Tired of that same old
cell phone?  Get a new here for FREE!
https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390




More information about the Users mailing list