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

Varnish scrape failed #62

Closed
CPC954 opened this issue Jun 17, 2020 · 3 comments
Closed

Varnish scrape failed #62

CPC954 opened this issue Jun 17, 2020 · 3 comments

Comments

@CPC954
Copy link

CPC954 commented Jun 17, 2020

  • Varnish 6.0.6
  • prometheus_varnish_exporter v1.5.2

Giving error:

Jun 17 11:45:01 varnish-a1 prometheus_varnish_exporter: Could not get hold of varnishd, is it running?
Jun 17 11:45:01 varnish-a1 prometheus_varnish_exporter: 2020/06/17 11:45:01 [ERROR] Startup test: varnishstat scrape failed: exit status 1

@lipov3cz3k
Copy link

When varnish runs as vcache user (default in systemd) this error occurs. Hot fix is to run prometheus-varnish-exporter service as same user instead of prometheus

/lib/systemd/system/prometheus-varnish-exporter.service
...
User=vcache
....

@lipov3cz3k
Copy link

If you run debian and use prometheus-varnish-exporter deb package, just add prometheus user to varnish group

usermod -G varnish -a prometheus

@jonnenauha
Copy link
Owner

Resolve what user varnishd is running as. First column of the results. ps -ef | grep varnishd.

Added link to this issue to README, seems this is fairly frequent problem.

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

3 participants