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
No data in Grafana / Follow up your advise #32
Comments
Have you added a scrape job to the prometheus.yml? Something like:
If so, on the targets page of Prometheus, is the endpoint marked as up? |
|
@JeromeX Do you have your prometheus server running on the same machine as the pi-hole-exporter? if this is the case then you need to set your domain to
|
Probably the same issue: |
Finally it's working - Yes :-) |
I mostly followed this:
And then these commands to enable it to automatically start on boot and to start it now, without having to wait for a reboot:
|
To do a query? Or do just see the 'up to 100 queries'? Depending on your network, you will never really see anything with the number of DNS requests that are made at any given time. Plus the dashboard isn't 'live' data, like constant, scrolling DNS requests. You could edit the dashboard, and a a link to http://pi-hole-ip-or-address/admin/queries.php to get to the page. Maybe make a feature request because it's not one of the data points (metrics registered) that the pihole_exporter handles. |
I see a couple of issues while deploying mine. Then, the dashboard import json from grafana web is different than the one here, in GitHub. While this one lets me select Prometheus as the data source, I still get no data on my dashboard. |
I'm having a similar issue to you @JonAnder83 however, after adding the rule you had, I got the following: Any idea on how to fix this? |
@JonAnder83 did you edit each graph to be Prometheus? @OfficialTehlo what hardware are you running? On a Pi itself? In a VM? Make sure the pihole_exporter is for your hardware. Did you follow the steps in the observability.blog link above with creating the user, etc.? The ExecStart line needs to be customised for your environment with the right executable, the right host, and the right password. |
Hi @rth9 yes I have, because when I run the command by itself, then I get the following: So on its own it's working fine, but in a systemd it isn't. |
You are using the exact same command to start it manually as you put in the ExecStart line? Issue #26 shows the same error? |
Nope. Funny thing: If you have multiple data sources (i.e. influxdb and prometheus) and set prometheus as the default data source, the import just works out of the box. Thanks though! |
@rth9 Yep, same command but still have the same issue. Any idea? |
Tried this once before and even today getting back to it, I'm still lost on how to make it show up in the graph. Using Docker-Compose in case anyone is wondering. I have it working on Prometheus, Tried using ./pihole_exporter -pihole_hostname 192.168.178.2 -pihole_password blablabla Can't bash into Ekofr-Pi-Hole |
If this works (make sure to change path to your executable and if it's not AMD64), I put single quote around my password: Then you can do the following should work to get it as a service. File path/name: I prefer nano, so: And put in these contents (mine is AMD64, your file may be different architecture or location), it requires that you created the "pihole_exporter" user account manually.:
Command to enable it as a service and auto-start on boot: You can then start it with this if you don't want to reboot: Looking at the status of the service or using journalctl should show essentially the same output as running the command manually. Don't run the command manually when the service is started. |
So you are using the ARM binary? Where my example above has amd64, you have replaced the commands to point to the arm binary? Your screenshot has a tick beside Prometheus, not Grafana, are you sure it's looking at the wrong place? I ran into a problem where my default was InfluxDB, I added Prometheus after, but had to update my dashboard to point to Prometheus instead of InfluxDB. Are you saying your default datasource was Grafana instead of InfluxDB or Prometheus? |
I had just recently added InfluxDB to try it out which im not getting much out of it. |
So you have data. I ended up going to edit the dashboard, not each graph, then JSON Model, copy and paste out, find and replace where it said "datasource": "default", and replaced it with "datasource": "Prometheus", and then copied and pasted it back in. That cleared up my graphs showing no or wrong data. |
ok. Changed one and looks like it replaced all of them for me except "datasource": null , which I had also replaced. |
Mine is still null and mine is also 9311. Your dashboard now is filled with graphs with no data? Not odd stuff like with InfluxDB or Grafana previously? Edit: |
Its just blank. Which node? edit..perhaps i should just give up on it. nice feature to look at. |
Where can i find the prometheus.yml to update the target? |
Sure, it work’s meanwhile fantastic and smooth, thanks for the info
Holen Sie sich Outlook für iOS
On Sat, Sep 5, 2020 at 8:36 AM +0200, "lkshck" <notifications@github.com> wrote:
@JeromeX Do you have your prometheus server running on the same machine as the pi-hole-exporter?
if this is the case then you need to set your domain to localhost and don't forget the port 9617
- job_name: pihole
honor_timestamps: true
metrics_path: /metrics
scheme: http
static_configs:
- targets: ["localhost:9617"]
Where can i find the prometheus.yml to update the target?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Can find this in |
I'm running the exporter as an docker image. So i'm not able to find the yml under this path. Is it somewhere else located in this case? |
@lkshck @rth9 Honestly, this could be alot better tho for the default without putting in so much tweaking into it. and the error of % ads blocked "O.toFixed is not a function" when selecting Premethuis |
Using now the typical installation of Prometheus and target looks ok from my point of view, but still HTTP Error Not Found. Any other ideas? Curl to 127.0.0.1:9617/metrics works fine on Pi. Recognized that URL in grafana http://localhost:9090 is working and dashboard looks like the following. How is this possible? :D |
@lkshck you don't want to add the |
@TehloWasTaken did that and i was able to save the datasource and dashboard is showing some data but not all of them. I thought i need to define http://localhost:9617 as i defined this in the prometheus job. Dashboard now looks like the following: |
@lkshck Looks like it's getting there! I'd make sure the missing metrics are in Prometheus, if they are not they will simply not be exported from your PiHole. Also, holy crap you block a lot of domains. You do know that more != better for PiHole right? 😛 |
@TehloWasTaken Yes I'm aware of that 😆 didn't found the best list setup for now. As i'm not that familiar with Prometheus. Any way to check if the is in Prometheus? Like Top queries by domain.. |
besides the last 2 post between my pic and your pic, we both up to 1787115 @lkshck |
I just installed on my Pi4 pihole as usal, installed prometheus as well go and going through your readme. Everything is running, but there is no way to see data in grafana. Can you help me? What do i need configure on grafana site? What's wrong, what must i check?
The text was updated successfully, but these errors were encountered: