Hello, I seem to be seeing some errors with prometheus.
Nov 6 13:53:54 mon05 prometheus[17576]: time="2017-11-06T13:53:54Z" level=error msg="Error reading file \"/opt/monitoring/snmp_exporter/snmp.yml\": yaml: unmarshal errors:\n line 1: cannot unmarshal !!map into []*config.TargetGroup" source="file.go:180"
Nov 6 13:53:59 mon05 prometheus[17576]: time="2017-11-06T13:53:59Z" level=error msg="Error reading file \"/opt/monitoring/snmp_exporter/snmp.yml\": yaml: unmarshal errors:\n line 1: cannot unmarshal !!map into []*config.TargetGroup" source="file.go:180"
Nov 6 13:54:54 mon05 prometheus[17576]: time="2017-11-06T13:54:54Z" level=info msg="Checkpointing in-memory metrics and chunks..." source="persistence.go:539"
Nov 6 13:55:01 mon05 prometheus[17576]: time="2017-11-06T13:55:01Z" level=info msg="Done checkpointing in-memory metrics and chunks in 7.487848821s." source="persistence.go:563"
I just want to make sure this may or may not be a syntax issue in my config.
In my prometheus.service file I have it looking like this:
ExecStart=/opt/monitoring/prometheus/prometheus -config.file /opt/monitoring/configs/prometheus.yml
In the prometheus.yml file it looks like this:
- job_name: 'juniper-snmp'
file_sd_configs:
- files: [ '/opt/monitoring/snmp_exporter/snmp.yml' ]
metrics_path: /juniper-snmp
params:
module: [ juniper ]
static_configs:
- targets:
- remote-ip
relabel_configs:
- source_labels: [__address__]
target_label: __param_target
- source_labels: [__param_target]
target_label: instance
- target_label: __address__
replacement: prometheus-ip:9116