2014-06-24 2 views
0

와 경고 (404) 우리 check_http의 모든 명령은 다음과 같은 메시지와 함께 경고를 던지기 시작했다 :의 Nagios 며칠 전에 check_http

운영 체제도 Nagios는 어느 쪽도 업데이트되거나 경고가 시작된 시간에 근처 어디서든 수정 된
Site Access - Images;WARNING;SOFT;1;HTTP WARNING: HTTP/1.1 404 Not Found - 492 bytes in 0.008 second response time

.

이는 CFG 파일의 항목 중 하나입니다 : 명령 줄에서

define service { 
    use     my-service 
    host_name   web01 
    service_description Site Access - MyApp 
    check_command  check_http!myapp.mydomain.com!-S --onredirect=follow 
    contact_groups  alert-admins 
} 

check_http가 잘 작동

: 명령 줄 버전이 작동 된 이후

./check_http -H myapp.mydomain.com -u /space.gif -f follow -v 

    GET /space.gif HTTP/1.1 
    User-Agent: check_http/v1.4.15 (nagios-plugins 1.4.15) 
    Connection: close 
    Host: myapp.mydomain.com 

    http://myapp.mydomain.com:80/space.gif is 307 characters 
    STATUS: HTTP/1.1 200 OK 

답변

0

, 나는 모두를 교체

define command { 
    command_name check_http-web01-myapp 
    command_line /usr/lib/nagios/plugins/check_http -H myapp.mydomain.com -f follow -S 
} 

define service { 
    use     my-service 
    host_name   web01 
    service_description Site Access - MyApp 
    check_command  check_http-web01-myapp 
    contact_groups  alert-admins 
} 

그리고 CHEC : check_http 실패하면 다음 (또는 유사한)와 함께 명령 ks가 다시 일하기 시작했습니다.

내가 Nagios 내의 check_http 명령 정의를 조사하고 그것이 무엇을하는지보아야한다는 것을 알았지 만 교체가 작동 중입니다 ...