Nagios Configuration of Windows

Source: Internet
Author: User

1.1 Windows Client Installation nsclient++
Note: After installation, you will be prompted to allow those hosts listen to add Nagios-server hosts. After installation will provide a password, remember to save, server side will use.
1.2 Enable cfg_file=/usr/local/nagios/etc/objects/windows.cfg in Nagios.cfg, if you need to monitor multiple Windows hosts, it is recommended to enable cfg_dir==/ Usr/local/nagios/etc/windows

1.3To configure TEMPLATES.CFG, add the following:
#windows Host
Define Host{
Name Windows; Template hostname (which can be defined by itself) for subsequent windows.cfg calls
Use Generic-host; Inherit default values from the Generic-host template
Check_period 24x7; Check cycle, can also be set to other, such as workhours, specific can be defined in the/usr/local/nagios/etc/object/timeperiod inside
Check_interval 5; Actively check the server every 5 minutes
Retry_interval 1; Schedule host check retries at 1 minute intervals
Max_check_attempts 10; Check each server ten times (max)
Check_command check-host-alive; Default command to check if servers is "alive"
Notification_period 24x7; Send alarm time period, that is, what time can send alarm to the administrator, as check_period as self-defined
Notification_interval 30; Alarm send cycle, here by default is the minute unit, 30 means to send an alarm every 30 minutes
Notification_options D,r; The level of alarm that needs to be sent, which is the alarm when something happens, and d means that down,r represents recovery
contact_groups admins; Contact a user group, which is the Administrator group to which the alert is sent
Hostgroups windows; Host group name (you can define it yourself):
Register 0; DONT REGISTER this-its JUST A TEMPLATE
}

#windows Service

Define Service{
Name Windows-service; Template service Name
Active_checks_enabled 1; Enable check, 1 means enabled, 0 means not enabled
Passive_checks_enabled 1; Passive Service Checks is enabled/accepted
Parallelize_check 1; Active service checks should is parallelized (disabling this can leads to major performance problems)
Obsess_over_service 1; focus on the service
Check_freshness 0; Default is to not check service ' freshness '
Notifications_enabled 1; Allow reminders
Event_handler_enabled 1; Enable event handlers
Flap_detection_enabled 1; Flap detection is enabled
Process_perf_data 1; Performance data
Retain_status_information 1; Hold status information

Retain_nonstatus_information 1; Preserve non-state information
Is_volatile 0; Service is stable, 1 is stable, 0 is unstable
Check_period workhours; Check cycle
Max_check_attempts 3; Recheck the service 3 times to determine its final status

Normal_check_interval 10; Under normal circumstances, check a service every 10 minutes

Retry_check_interval 2; Recheck every 2 minutes until an abnormal state can be determined

contact_groups admins; Contact Group
Notification_options W,u,c,r; Alarm level warning, unknown, critical,recovery

Notification_interval 60; Period of sending alarms
Notification_period workhours; Time period for sending alarms

Register 0

}


1.4Configure Windows.cfg
Define Host{
Use Windows; The host template that is configured in Templates.cfg is called here
HOST_NAME PC-1; Host Name
Alias Test 1; Host aliases
Address 192.168.1.3; Host IP
}
Define Hostgroup{
Hostgroup_name windows; Group to which the host belongs
Alias Windows Cline; Group name
Member PC-1; group members
}

Define Service{
Use Windows-service; Call template for service in templates
HOST_NAME PC-1; Which host, if there are more than one, separated by commas
Service_description nsclient++ Version; service profile, which will be displayed in the Web page
Check_command check_nt! clientversion-s password; password is sclient++ 's code.
}

Define Service{
Use Windows-service
HOST_NAME PC-1
Service_description c \ Drive Space
Check_command check_nt! Useddiskspace!-l c-w 90-c 99-s password;-L followed by a disk character

}

This article is from the "Houyang Linux articles" blog, so be sure to keep this source http://yanglulinux.blog.51cto.com/2809000/1684576

Nagios Configuration of Windows

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.