Https 如何在Nagios中使用intern ssl证书监控路由器?

Https 如何在Nagios中使用intern ssl证书监控路由器?,https,ssl-certificate,nagios,network-monitoring,check-mk,Https,Ssl Certificate,Nagios,Network Monitoring,Check Mk,这是我当前的设置: 主机配置: define host{ use generic-host ; Inherit default values from a template host_name A+A ; The name we're giving to this host alias A+A Objektausstattung Router ; A longer name associated with the host

这是我当前的设置:

主机配置:

define host{

use     generic-host        ; Inherit default values from a template

host_name       A+A         ; The name we're giving to this host

alias       A+A Objektausstattung Router    ; A longer name associated with the host

address         https://87.139.203.190:444  ; IP address of the host

hostgroups      Router      ; Host groups this host is associated with

}
服务配置:

define service{

use     generic-service     ; Inherit default values from a template

host_name       A+A

service_description HTTP

check_command   check_http

}
我将从Nagios获得此错误:

检查\u icmp:未能解决


我做错了什么?

Nagios试图解析ip地址和端口。请仅尝试ip地址

address         https://87.139.203.190  ; IP address of the host

您的主机定义应仅为“地址”指定IP地址。URL不是主机的属性,而是要执行的HTTP检查的属性

服务定义指定check_命令,该命令依次在
checkcommands.cfg
文件中定义。这将确切地指定要运行的命令,可能使用传递的其他参数

您可能希望将端口号作为参数传递,并且希望使用HTTPS。如何执行此操作将取决于您的设置。例如,您可以在
checkcommands.cfg中使用此选项:

define command{
    command_name    check_https
    command_line    $USER1$/check_http -t 12 -H $HOSTADDRESS$ -f ok --ssl=1 -u "$ARG1$" -p "$ARG2$" -w $ARG3$ -c $ARG4$
    }
然后,您可以使用checkcommand配置您的服务,如下所示:

check_command check_https!/!444!1!5
这将检查url
http://87.139.203.190:444/
,如果超过1s,则发出警告;如果超过5s,则发出严重警告。将使用TLSv1(否则您可能会在带有贵宾犬保护的web服务器上得到误报)