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

Fix systemd example for configuring nginx_exporter.service #650

Merged
merged 2 commits into from
Jun 21, 2024
Merged

Fix systemd example for configuring nginx_exporter.service #650

merged 2 commits into from
Jun 21, 2024

Conversation

bruno-espino
Copy link
Contributor

@bruno-espino bruno-espino commented Feb 26, 2024

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.

  • I have read the CONTRIBUTING
    guide
  • I have proven my fix is effective or that my feature works
  • I have checked that all unit tests pass after adding my changes
  • I have ensured the README is up to date
  • I have rebased my branch onto main
  • I will ensure my PR is targeting the main branch and pulling from my branch on my own fork

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
@bruno-espino bruno-espino requested a review from a team as a code owner February 26, 2024 23:39
@github-actions github-actions bot added the bug An issue reporting a potential bug label Feb 26, 2024
Copy link

nginx-bot bot commented Feb 27, 2024

Hi @bruno-espino!

Thanks for opening this pull request!
Be sure to check out our Contributing Guidelines while you wait for someone on the team to review this.

@nginx-bot nginx-bot bot added the community label Feb 27, 2024
Copy link
Member

@lucacome lucacome left a comment

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
Copy link

brunococinoJC commented Feb 27, 2024

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

@lucacome lucacome added the community Issues or PRs opened by an external contributor label Apr 5, 2024
@jjngx
Copy link
Contributor

jjngx commented Jun 20, 2024

Hi @brunococinoJC , I will be testing it tomorrow.

@jjngx jjngx enabled auto-merge (squash) June 21, 2024 09:04
@jjngx
Copy link
Contributor

jjngx commented Jun 21, 2024

@brunococinoJC thanks for contributing

@jjngx jjngx merged commit 742685a into nginxinc:main Jun 21, 2024
13 checks passed
@bruno-espino bruno-espino deleted the fix/systemd-example branch June 22, 2024 18:42
@lucacome lucacome added documentation Pull requests/issues for documentation and removed bug An issue reporting a potential bug labels Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community Issues or PRs opened by an external contributor documentation Pull requests/issues for documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants