InfluxDB 2 OSS integration with Grafana using InfluxQL

Hello I am trying to integrate grafana with influx as in this guide:

I have completed all the steps including:

Everything checks out, if I run a get with my user’s token the mapping appears to be fine.

Am I missing something?
I have to note it does feel weird to choose Basic Auth and a pair of username & token.
Is anything wrong with the documentation?
I tried to use auth headers and still nothing.

The related influx log is: 2020-11-23T21:34:58.227170Z info Unauthorized {“log_id”: “0Qel1170000”, “error”: “authorization not found”}

And the error on grafana: “Bad Request”

InfluxDB version 2.0.2
Grafana version: 7.3.3

Any help will be appreciated!

Hello @gpanou,
So just to make sure I understand you correctly, you’re trying to query 2.x with influxQL in grafana? What’s throwing me off is why did you execute dbrp mapping?
I’m not a grafana user, but can you use the plugin? https://grafana.com/grafana/plugins/grafana-influxdb-flux-datasource

I need InfluxQL support because all the Grafana community dashboards are created for 1.x right now.
So flux would not work for my monitoring needs.

I figured it out, I was suspicious about basic auth using a token. Indeed you need to authenticate with an Authorization header, including the “Token” part of the string.

Should I open an issue regarding the documentation somewhere?

@gpanou Sure I too found that confusing when I first tried. Maybe here? https://github.com/influxdata/docs-v2
Thank you!

Hi @gpanou, I’m glad to hear you got things working. I’ve been hunting/squishing problems in our V1 compatibility APIs, could you clarify a few details?

  • When you were trying to use Basic Auth and hitting errors, were you using the username/password of a V2 user (created via influx setup or influx user create)? Or a V1 compatibility user (created via influx v1 auth create)?
  • Same question now that you’re using Token auth and things are working: are you using V2 creds, or V1?

Thanks for your help!