Prometheus远程读取influxdb [英] Prometheus remote read influxdb

查看:147
本文介绍了Prometheus远程读取influxdb的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Prometheus的新手,但熟悉Influx(当前运行1.6).

I'm new to Prometheus but familiar with Influx (currently running 1.6).

我的理解是,可以将Prometheus配置为使用prometheus.yml中的以下配置远程从流入中读取数据:

My understanding is it's possible to configure Prometheus to remotely read data from influx with the following configuration in prometheus.yml:

remote_read:
  url: "http://localhost:8086/api/v1/prom/read?db=bulkstats"

"bulkstats"是我试图从Prometheus中读取数据的数据库.可能会大量涌入的查询示例为:

"bulkstats" is the database I'm trying to read data from in Prometheus. An example query that would work in influx would be:

SELECT "sess-curaaaactive" FROM "PDSNSYSTEM1" WHERE ("Nodename" = 'ALPRGAGQPNC') AND time >= now() - 6h"

但是我找不到一个如何从PromQL查询该数据的示例.请帮忙!

However I cannot find one example of how to query that data from PromQL. Please help!

推荐答案

Here is the link which matches prometheus format with influxdb's one.

就普罗米修斯的行话而言,在您的示例中, sess-curaaaactive 是度量名称(流入量),而("Nodename" ='ALPRGAGQPNC')是只是普罗米修斯附在测量值上以创建时间序列的标签.

In terms of prometheus's jargon, in your example, sess-curaaaactive is the metric name (measurement in influx) and ("Nodename" = 'ALPRGAGQPNC') is just a label which prometheus attaches to the measurement to create a time series.

这篇关于Prometheus远程读取influxdb的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆