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

Add Influxdb v2 workaround to docs #407

Closed
LoeschMaximilian opened this issue Apr 5, 2022 · 4 comments · Fixed by #456
Closed

Add Influxdb v2 workaround to docs #407

LoeschMaximilian opened this issue Apr 5, 2022 · 4 comments · Fixed by #456
Labels
docs Documentation request or update

Comments

@LoeschMaximilian
Copy link

Hi

UniFi Poller can talk to InfluxDB 2.0 using DBRP mappings : https://docs.influxdata.com/influxdb/v2.0/tools/grafana/?t=InfluxQL#view-and-create-influxdb-dbrp-mappings

Once your InfluxDB 2.0 bucket is created (using CLI or 8086 web UI) :

# influx bucket list
ID                      Name                    Retention       Organization ID
f2763f172b50dea3        _monitoring             168h0m0s        143f24876e1ec5d2
74e9f584fccacedc        _tasks                  72h0m0s         143f24876e1ec5d2
7112dfae5d1aa164        unifi                   8760h0m0s       143f24876e1ec5d2

# influx v1 dbrp create --db unifi-db --rp unifi-rp --bucket-id  7112dfae5d1aa164 --default
ID                      Database        Bucket ID               Retention Policy        Default Organization ID
075053f3abe50000        unifi-db        7112dfae5d1aa164        unifi-rp                true    143f24876e1ec5d2

# influx v1 auth create  --read-bucket 7112dfae5d1aa164 --write-bucket 7112dfae5d1aa164 --username unifi-user
Please type your password: 

Please type your password again:

You then just have to fill up.conf :

[influxdb]
  disable = false
  url  = "http://influxdb:8086"
  user = "unifi-user"
  pass = "mysuperpassword"
  db = "unifi-db"

Originally posted by @Fredouye in #255 (comment)

@ituri
Copy link

ituri commented May 23, 2022

Which settings do you use for Grafana? I'm having trouble adding a datasource with those settings.

@ilbarone87
Copy link

Has anyone managed to make the dashboard work? Mine seems not getting any data, even if I can see they're flowing to DB in influxDB GUI and on unpolled logs seems to receive them.
In grafana seems that the right DB is not showing even if test & save works fine

@pauly2805
Copy link

pauly2805 commented Sep 28, 2022

I had to do an additional step for it to work - initially, influxDB appeared fine, grafana test & save was happy, but had no data.
This post worked for me: https://community.influxdata.com/t/influxdb-error-retention-policy-not-found-autogen/26352/6

basically just had to type the following in cli (after already creating the v1 dbrp bucket):
influx v1 dbrp create --db unifi --rp autogen --bucket-id

This then turns 'influx v1 dbrp list' 'Default' field for unifi, to false, and this somehow makes everything work...all the dashboards working great for me with grafana 9.1.6 and influxdb 2.4 :)

@ilbarone87
Copy link

Screenshot 2022-11-28 at 00 44 00

I'm still getting these errors in my dashboard

This was referenced Dec 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation request or update
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants