-1

Jul 05 14:00:25 ip-19-0-1-16.ec2.internal heartbeat[13996]: 2019-07-05T14:00:25.518Z ERROR instance/beat.go:877 Exiting: could not create monitor: job err missing required field accessing ‘heartbeat...heartbeat.yml’) Jul 05 14:00:25 ip-19-0-1-16.ec2.internal heartbeat[13996]: Exiting: could not create monitor: job err missing required field accessing ‘heartbeat.monitors.0.hosts’ (source:‘/etc/heartbeat/heartbeat.yml’)

karthik sl17
  • 19
  • 1
  • 7

2 Answers2

0

Open yml file and edit it to map to required config ,uncomment of few lines will be needed.

0

Just do it as follows (in heartbeat-7.8.0) :

heartbeat.monitors.0.hosts: ["<es-ip>:9200"]
heartbeat.monitors.0.type: http
heartbeat.monitors.1.type: tcp
heartbeat.monitors.2.type: tcp
heartbeat.monitors.0.schedule: '@every 30s'
heartbeat.monitors.1.schedule: '@every 30s'
heartbeat.monitors.2.schedule: '@every 30s'
heartbeat.monitors.1.hosts: ["<redis-ip>:6379"]
heartbeat.monitors.2.hosts: ["<postgres-ip>:5432"]

let's say your applications to monitor are 3, start with 0 indexing.

beneath that, I have my usual heartbeat.monitors section as follows :

heartbeat.monitors:
- type: http
  id: es-monitor
  name: ES Monitor
  urls: ["<es-ip>:9200"]
  schedule: '@every 30s'
- . . .
khanna
  • 718
  • 10
  • 24