Fix systemd example for configuring nginx_exporter.service

by bruno-espino · Pull Request #650 · nginx/nginx-prometheus-exporter (original) (raw)

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 andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

jjngx merged 2 commits intonginx:mainfrombruno-espino:fix/systemd-example

Jun 21, 2024

Conversation5 Commits2 Checks12 Files changed

Conversation

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})

bruno-espino

when implementing nginx exporter, I used the example under examples/systemd but I was not seeing my nginx stub metrics.
When enabling journal logging for the service and checking with systemctl status nginx_exporter -l I could see the nginx.scrape-uri was not being parsed correctly. Hence why I couldn't see my stub metrics.
After removing both "" I was able to see my metrics

Checklist

Before creating a PR, run through this checklist and mark each as complete.

@bruno-espino

when implementing nginx exporter, I was not seeing my nginx stub metrics. When enabling journal logging for the service and checking with "systemctl status nginx_exporter -l" I could see the nginx.scrape-uri was not being parsed correctly. Hency why I couldn't see my stub metrics. After removing both "" I was able to see my metrics

@nginx-bot nginx-bot

lucacome

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @bruno-espino thanks for opening the PR!

Just out of curiosity, which OS/version are you using? I tried this on Ubuntu 23.10 and it's not complaining about the quotes, it's just stripping them out...

@brunococinoJC

Hi @bruno-espino thanks for opening the PR!
Just out of curiosity, which OS/version are you using? I tried this on Ubuntu 23.10 and it's not complaining about the quotes, it's just stripping them out...

Hey @lucacome!
I faced this issue on Amazon Linux 2, with systemd version 219
Maybe it's not the OS but the systemd version, which is quite old and might not support the quotes for parsing

@jjngx

jjngx

@jjngx

@jjngx

@lucacome lucacome added documentation

Pull requests/issues for documentation

and removed bug

An issue reporting a potential bug

labels

Jun 26, 2024

This was referenced

Jul 28, 2024

Labels

community

Issues or PRs opened by an external contributor

documentation

Pull requests/issues for documentation