henrywhitaker3 / Speedtest-Tracker

Continuously track your internet speed
GNU General Public License v3.0
1.54k stars 121 forks source link

[HELP] Guide for using Influx db with Speedtest-Tracker #954

Open nodecentral opened 2 years ago

nodecentral commented 2 years ago

Hi

Does anyone have an idiots (noobs) guide to create a Docker influx db instance/container and the associated database to work with Speedtest-Tracker ? Many thanks …

masterwishx commented 2 years ago

Also interesting if we can somehow adopt influxDBv1 to use with InfluxDBv2

luisfocosta commented 2 years ago

I am also having difficulties saving data in my InfluxDB. Speedtest does not seem to try to contact the database and I can't find any log entry in speedtest.

masterwishx commented 2 years ago

Do you mean influxdb1 or influxdb2?

alexdelprete commented 2 years ago

I am also having difficulties saving data in my InfluxDB. Speedtest does not seem to try to contact the database and I can't find any log entry in speedtest.

Working fine here, nothing special in the config, just the server hostname/port and user/pw:

image

I then found a speedtest dashboard in grafana library that I had to modify/adapt to work with speedtest-tracker:

image

1aranzant commented 2 years ago

Same... can't link them :/

richterscale17 commented 2 years ago

I am also having difficulties saving data in my InfluxDB. Speedtest does not seem to try to contact the database and I can't find any log entry in speedtest.

Working fine here, nothing special in the config, just the server hostname/port and user/pw:

image

I then found a speedtest dashboard in grafana library that I had to modify/adapt to work with speedtest-tracker:

image

Can you share your Grafana config?

alexdelprete commented 2 years ago

Can you share your Grafana config?

I uploaded it to Grafana dashboard library: https://grafana.com/grafana/dashboards/16339

If @henrywhitaker3 wants, he can reference it in the install/config instructions.

richterscale17 commented 2 years ago

I uploaded it to Grafana dashboard library: https://grafana.com/grafana/dashboards/16339

Thank you!

masterwishx commented 2 years ago

Working fine here

Do you using influxdb1 right? But is it possible to use influxdb1 inside influxdb2?

alexdelprete commented 2 years ago

Speedtest Tracker has support for influxdb1.

I read that in some way you can use influxdb2 for apps designed for influxdb1 by passing the config parameters in a certain way, but I simply decided to have influxdb1 and influxdb2 in my homelab without doing weird stuff. :)

masterwishx commented 2 years ago

Thanks, yes its simpliest way ti use influxdb1 . but im trying now to make influxdb1 in influxdb2 , and i made it by console commands like its wrote in docker page of influxdb when building docker but now im trying to connect it to grafana having some error

1aranzant commented 2 years ago

Ohhh I was trying with db2... lol thanks

masterwishx commented 2 years ago

i can see data from speedtracker in db2 but cant get it into grafana yet ...

image

alexdelprete commented 2 years ago

when you create a dash in grafana you simply have to select the influxdb2 connector. I use grafana with both influxdb1 and 2.

masterwishx commented 2 years ago

i selected but cant see nothing in dashboard

masterwishx commented 2 years ago

image

alexdelprete commented 2 years ago

check first if you have data in influxdb1, through its interface:

image

once you're sure there's data coming in influxdb1 from speedtest-tracker, then add the datasource to grafana like this:

image

nodecentral commented 2 years ago

Hi, Does anyone have a working Docker run/Compose file they can share from InfluxdB ? I’ve tried various guides but it’s not worked, hoping someone has a tried and tested one they can share - Thanks in advance..

nodecentral commented 2 years ago

Ok, managed to get influxdb installed on my QNAP (https://ac20202021.medium.com/how-to-setup-influxdb-and-grafana-on-qnap-nas-a70a3ae91ae5)

Flying a little blind here, but I’ve created a ‘bucket’ called ‘speedtest-tracker’ and added my influx config under Speedtest settings.

11B13ECF-92D9-41B3-BA12-214E332C1072

To get things going and help build out the dB structure, I assumed I could take a csv backup of my data and upload it - but it seems that’s not as straightforward as I hoped - as I get the following error.

3415A222-A977-402A-8E09-BFA0E5DF93A6

How did other people populate their dB?

masterwishx commented 2 years ago

check first if you have data in influxdb1, through its interface:

im trying to use influxdbv2 bucket that using influxdbv1

masterwishx commented 2 years ago

i dont have expirience with influxdb at all but will try make it working on influxdbv2 from influxdbv1 client speedtest-tracker

image

masterwishx commented 2 years ago

check first if you have data in influxdb1, through its interface

i have it but in influxdb2 and if add it to grafana then i have all data but checking how more right to add it for now ...

also made dashboard in influxdbv2

image

masterwishx commented 2 years ago

Finaly builded sppedtest tracker on bucket linked to influxdbv1 in influxdbv2 on grafana on 16339 if someone interested i can write the steps here its not the easyest way .... but the easy way just install influxdbv1 )

masterwishx commented 2 years ago

image

masterwishx commented 2 years ago

Ok, managed to get influxdb installed

You need to make dbv1 and auth for bucket from console ...

masterwishx commented 2 years ago

Finaly uploaded my dashboard to Grafana with instructions Speedtest Tracker - InfluxDBv2 https://grafana.com/grafana/dashboards/16428