1、监控页面 客户端 使用自带的check_http command[check_www_web]=/usr/local/nagios/libexec/check_http -H www.baidu.com -u /index.php 亦可使用首页的图片文件 command[check_bbs_web]=/usr/local/nagios/libexec/check_http -H bbs.baidu.com -u /index.php 服务端 define service{ use admin-service ; Name of service template to use host_name app1 service_description check_admin check_command check_nrpe!check_www_web } 2、监控DNS 定义检查命令commands.cfg #check_dns define command{ command_name check_dns command_line $USER1$/check_dns -H $ARG1$ -s $ARG2$ -w 1 -c 2 } 修改服务server.cfg define service{ use admin-service ; Name of service template to use host_name ns1 service_description check_dns check_command check_dns!www.baidu.com!192.168.1.5 } |
|