我正在尝试Kibana中的正常运行时间功能。我已经下载了心跳并使用默认设置运行它。还行吧
但是,当我尝试在heartbeat.monitors
的heartbeat.yml
中添加更多监视器时。我遇到一个错误。
以下为默认值,运行正常。haertbeat.yml
# Configure monitors inline
heartbeat.monitors:
- type: http
# List or urls to query
urls: ["http://localhost:9200"]
# Configure task schedule
schedule: '@every 10s'
# Total test connection and data exchange timeout
#timeout: 16s
但是,当我添加以下内容时,出现错误。
# Configure monitors inline
heartbeat.monitors:
- type: http
# List or urls to query
urls: ["http://localhost:9200"]
# Configure task schedule
schedule: '@every 10s'
# Total test connection and data exchange timeout
#timeout: 16s
- type: icmp <------ When I try to add tcp or icmp,
schedule: '@every 10s' <------ I get an error. I am doing something
hosts: ["localhost"] <------ wrong. How can I add more monitors?
PS C:\Program Files\Heartbeat> Start-Service heartbeat
Start-Service : Service 'heartbeat (heartbeat)' cannot be started due to the following error: Cannot start service heartbeat on computer '.'.
At line:1 char:1
+ Start-Service heartbeat
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OpenError: (System.ServiceProcess.ServiceController:ServiceController) [Start-Service], ServiceCommandException
+ FullyQualifiedErrorId : CouldNotStartService,Microsoft.PowerShell.Commands.StartServiceCommand
[当我删除要添加的内容时,效果很好。如何在heartbeat.yml
中添加更多监视器?
我在Linux环境中执行了上述操作,并且可以正常工作。我认为Windows环境中存在错误。