Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prometheus config for postfix exporter #70

Open
muscat-pl opened this issue Feb 16, 2021 · 2 comments
Open

Prometheus config for postfix exporter #70

muscat-pl opened this issue Feb 16, 2021 · 2 comments

Comments

@muscat-pl
Copy link

Hi,
I'm looking for any ready config for postfix exporter for prometheus.yml but can't find anything.
Could anybody help me with that ?

@tokul
Copy link

tokul commented May 31, 2022

It integrates same way as node exporter only port is different. Main problem is not configuring prometheus, but figuring how to convert fetched data into something useful.

- job_name: 'Postfix'
static_configs:
- targets: ['hostname1:9154']
- targets: ['hostname2:9154']

relabel_configs:
- source_labels: [__address__]
regex: "([^:]+):\\d+"
target_label: instance

Just remember yml layout as you see messed up layout in this post.

@maxkratz
Copy link

Just remember yml layout as you see messed up layout in this post.

You can use multiline code blocks here :).

- job_name: 'Postfix'
  static_configs:
    - targets: ['hostname1:9154']
    - targets: ['hostname2:9154']
  
  relabel_configs:
    - source_labels: [__address__]
    regex: "([^:]+):\\d+"
    target_label: instance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants