Prometheus Config for SNMP exporter

The configuration for the SNMP exporter inPrometheus should look like:

  - job_name: 'snmp'
      - targets:
        -  # SNMP device.
      module: [default]
      - source_labels: [__address__]
        regex: (.*?)(:80)?
        target_label: __param_address
        replacement: ${1}
      - source_labels: [__param_address]
        regex: (.*)
        target_label: instance
        replacement: ${1}
      - source_labels: []
        regex: .*
        target_label: __address__
        replacement:  # SNMP exporter.

Add all your targets to the list of targets, or use service discovery.

Rate this tip

If you think this tip by bbrazilbbrazil is useful — rate it up!

rating: +1+x
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License