nagios4/sample-config/template-object/windows.cfg.in

142 lines
4.0 KiB
INI
Raw Permalink Normal View History

2017-05-19 22:22:40 +02:00
###############################################################################
# WINDOWS.CFG - SAMPLE CONFIG FILE FOR MONITORING A WINDOWS MACHINE
#
#
# NOTES: This config file assumes that you are using the sample configuration
2019-04-18 17:09:18 +02:00
# files that get installed with the Nagios quickstart guide.
2017-05-19 22:22:40 +02:00
#
###############################################################################
###############################################################################
#
# HOST DEFINITIONS
#
###############################################################################
# Define a host for the Windows machine we'll be monitoring
# Change the host_name, alias, and address to fit your situation
2019-04-18 17:09:18 +02:00
define host {
2017-05-19 22:22:40 +02:00
2019-04-18 17:09:18 +02:00
use windows-server ; Inherit default values from a template
host_name winserver ; The name we're giving to this host
alias My Windows Server ; A longer name associated with the host
address 192.168.1.2 ; IP address of the host
}
2017-05-19 22:22:40 +02:00
###############################################################################
#
# HOST GROUP DEFINITIONS
#
###############################################################################
# Define a hostgroup for Windows machines
# All hosts that use the windows-server template will automatically be a member of this group
2019-04-18 17:09:18 +02:00
define hostgroup {
2017-05-19 22:22:40 +02:00
2019-04-18 17:09:18 +02:00
hostgroup_name windows-servers ; The name of the hostgroup
alias Windows Servers ; Long name of the group
}
2017-05-19 22:22:40 +02:00
###############################################################################
#
# SERVICE DEFINITIONS
#
###############################################################################
# Create a service for monitoring the version of NSCLient++ that is installed
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description NSClient++ Version
check_command check_nt!CLIENTVERSION
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring the uptime of the server
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description Uptime
check_command check_nt!UPTIME
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring CPU load
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description CPU Load
check_command check_nt!CPULOAD!-l 5,80,90
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring memory usage
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description Memory Usage
check_command check_nt!MEMUSE!-w 80 -c 90
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring C:\ disk usage
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description C:\ Drive Space
check_command check_nt!USEDDISKSPACE!-l c -w 80 -c 90
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring the W3SVC service
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
use generic-service
host_name winserver
service_description W3SVC
check_command check_nt!SERVICESTATE!-d SHOWALL -l W3SVC
}
2017-05-19 22:22:40 +02:00
# Create a service for monitoring the Explorer.exe process
# Change the host_name to match the name of the host you defined above
2019-04-18 17:09:18 +02:00
define service {
2017-05-19 22:22:40 +02:00
2019-04-18 17:09:18 +02:00
use generic-service
host_name winserver
service_description Explorer
check_command check_nt!PROCSTATE!-d SHOWALL -l Explorer.exe
}