Use remote storage adapter to write to multiple inluxdb

866 views
Skip to first unread message

abhijit...@gmail.com

unread,
Nov 14, 2017, 9:17:15 AM11/14/17
to Prometheus Users
I have a node exporter installed and running. I also have a prometheus instance installed. I am scraping data from the node exporter in the prometheus instance.
Now my goal is to install two influxdb instances in two separate machines.
Then use remote storage adapter to make the installed prometheus write into both the instances of influxdb.
Are there any configurations which I have to tweak to support multiple instances of influxdb?

Please note:
I have been able to establish this entire setup with a single influxdb instance. I am also seeing node exporter data in the influx database. 

Please suggest.

neha...@gmail.com

unread,
Mar 13, 2018, 6:56:40 PM3/13/18
to Prometheus Users
HI Abhijit,
Did you have any success in implementing influxdb HA with prometheus remote write api? I am tried using influx-relay to copy data to two influx-db but it seems to be not working with Prometheus write endpoint /api/v1/prom/write.

Thanks

addepalli...@gmail.com

unread,
Feb 26, 2019, 8:48:58 PM2/26/19
to Prometheus Users
Hi,


It says that one can have multiple remote writes and multiple remote reads.
Prometheus writes the data to all remote storage systems and also read from multiple remote storage systems.
So, there is no need for external software such as influx-relay. You can put all influxDB instances as remote_writes and remote_reads, you should see the data in all influxDB instances.

Srini

Murali Krishna Kanagala

unread,
Feb 27, 2019, 7:50:13 PM2/27/19
to Prometheus Users
All you need is to install influxdb, create a database on it and add the below line in prometheus.yml

remote_write:
- url: "http://influxdb_host:influxdb_port/api/v1/prom/write?u=paul&p=foo&db=prometheus"


avir...@gmail.com

unread,
Apr 15, 2019, 12:33:03 PM4/15/19
to Prometheus Users
Hi,

I wanted to write my prometheus data to multiple influxDB instances. I am able to write to a single DB. Can anyone suggest how to make things work for 2 different remote_write's?
I tried below which did not work..

remote_write:
- url: "http://influxdb_host:influxdb_port/api/v1/prom/write?u=paul&p=foo&db=prometheus"
- url: "http://influxdb_host:influxdb_port/api/v1/prom/write?u=paul&p=foo&db=prometheus1"

Callum Styan

unread,
Apr 17, 2019, 6:42:19 PM4/17/19
to Prometheus Users
Can you give more info? Your logs?

You should be able to add a second URL like that.

avir...@gmail.com

unread,
Apr 25, 2019, 4:50:57 AM4/25/19
to Prometheus Users
It took time but worked.

Maria Stroe

unread,
Feb 6, 2020, 4:38:56 AM2/6/20
to Prometheus Users

How did you manage to do that?
Reply all
Reply to author
Forward
0 new messages