- 论坛徽章:
- 0
|
服务端
nrpe.cfg
command[check_http]=/usr/local/nagios/libexec/check_http -w 30% -c 10%
commands.cfg
define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
}
define command{
command_name check_http
command_line $USER1$/check_http $ARG1$
}
remote-linux.cfg
define service {
use generic-service;
host_name pctheme
service_description HTTP
check_command check_nrpe!check_http
notifications_enabled 0
}
受控端
nrpe.cfg
command[check_http]=/usr/local/nagios/libexec/check_http -w 20% -c 10%
要实现监控http站点是否正常,不知应该如何设置的,监控网站为http://www.bac.com/index.htmlnagios返回的结果为"NRPE: Command 'check_http' not defined ",不知何原因???
在服务直接执行
./check_http -H www.bac.com -u /index.html
命令,没有问题的.返回正确的值 |
|