how to avoid multi prometheus instances remote write

1/23/2019

i wanna set up prometheus ha in production environment.

enter image description here

-- user6728754
kubernetes
prometheus

1 Answer

1/24/2019

For long storage this type of structure is build. The solution is you can send your samples from prometheus to other clustered storage system. Remote write sends samples as they are ingested to another system. Remote read allows PromQL to transparently use samples from another system, as if it were stored locally within the Prometheus. For this you can edit your prometheus.yml and write those rules.

remote_write:
    - url: http://localhost:1234/write
remote_read:
    - url: http://localhost:1234/read

You have to enable write_relabel_configs flag for the service.

-- Yeahia Md Abid
Source: StackOverflow