I have installed Prometheus in Kubernetes and I am trying to use remote_write and remote_read option to InfluxDB. I have created a user in DB with read and write privilege also. But I am receiving an error like this
http://url:port/api/v1/prom/write?db=dbname&u=xxx&p=yyy msg=non-recoverable error" count=100 err="server returned HTTP status 401 Unauthorized: {\"error\":\"authorization failed\"}"
and my configuration for prometheus is
prometheus.yml: |-
global:
scrape_interval: 5s
evaluation_interval: 5s
rule_files:
- /etc/prometheus/prometheus.rules
remote_write:
- url: "http://url:port/api/v1/prom/write?db=dbname&u=xxxx&p=yyy"
remote_read:
- url: "http://url:port/api/v1/prom/read?db=dbname&u=xxx&p=yyy"