Batch Kapacitor Tick to Influx 2


Can someone confirm what should the Kapacitor config have in the user and password fields of influxdb to be able to read and write in a batch tick to InfluxDB 2?

I’ve tried setting the password field with the Influx admin token as per the documentation and also “username:password” and I’m getting a 401 in both scenarios.

Dbrp is configured to my bucket and I’m using that DB and RP in the tick script.


Hello @rafaelnogueira13,
Are you able to test the compatibility successfully?

curl --request GET \
  --user "username:YourAuthToken" \
  --data-urlencode "db=mydb" \
  --data-urlencode "q=SELECT used_percent FROM mem WHERE host=host1"

No, I get “Unauthorized”. Can only get it to work with the Authorization token in the header of the call.

The type of request below, with Authorization header, works:

curl --request GET \
  --header "Authorization: Token YourAuthToken" \
  --data-urlencode "q=SELECT used_percent FROM example-db.example-rp.example-measurement WHERE host=host1"

Hello @rafaelnogueira13,
Hmm I’m not sure at the moment. I’ll share with experts and also try it for myself.
Thanks for your patience.

I got same issue in UAT as I had to fall back to use Kapacitor like with 1.8.x version
But I got 401 for any Kapacitor queries using Full access token.
Chronograf queries work fine.

I wrote Flux tasks for Alert Process down (similar as Tick script working perfectly in 1.8) but if I enable those, influxdb process goes berserker to 1200% and all grafana dashboard are stuck.
Stopping all tasks, grafana worked again as influxdb process resume.
Not good at all.

I even thinking to rollback to 1.8.x for influxdb version now.

influxdb: 2.0.3
Kapacitor:, i tired similar issue

A little more color on this, issue seems related to Flux script.
I rollback to Influxdb 1.8 and enable fluxscript, I change dashboard to use fluxscript and enable alert with Kapacitor → conclusion it crash Influxdb 1.8

Then I disable fluxscript in influxdb 1.8, and use back influxql, manage to replicate my dashboard using Influxql and enable alert - Process influxdb 1.8 run perfectly fine.

FYI, Dashboard monitor show the process up/down, cpu, memory inside a table, if process down, we can still see the process name per instance.

So it look like an issue with fluxscript to me.