gpt4 book ai didi

influxdb - 如何设置telegraf statsd(influxdb)的时间精度?

转载 作者:行者123 更新时间:2023-12-04 15:39:02 30 4
gpt4 key购买 nike

我正在使用 telegrafinfluxdb ,并在 telegraf我正在使用 statsd_input 插件。
statsd_input.conf :

[[inputs.statsd]]
## Address and port to host UDP listener on
service_address = ":8126"

## The following configuration options control when telegraf clears it's cache
## of previous values. If set to false, then telegraf will only clear it's
## cache when the daemon is restarted.
## Reset gauges every interval (default=true)
delete_gauges = true
## Reset counters every interval (default=true)
delete_counters = true
## Reset sets every interval (default=true)
delete_sets = true
## Reset timings & histograms every interval (default=true)
delete_timings = true

## Percentiles to calculate for timing & histogram stats
percentiles = [90]

## separator to use between elements of a statsd metric
metric_separator = "."

## Parses tags in the datadog statsd format
## http://docs.datadoghq.com/guides/dogstatsd/
parse_data_dog_tags = true

## Statsd data translation templates, more info can be read here:
## https://github.com/influxdata/telegraf/blob/master/docs/DATA_FORMATS_INPUT.md#graphite
# templates = [
# "cpu.* measurement*"
# ]

## Number of UDP messages allowed to queue up, once filled,
## the statsd server will start dropping packets
allowed_pending_messages = 10000

## Number of timing/histogram values to track per-measurement in the
## calculation of percentiles. Raising this limit increases the accuracy
## of percentiles but also increases the memory usage and cpu time.
percentile_limit = 1000

我正在尝试将时间精度设置为秒 .我试图在 telegram.conf 中完成此操作文件,但在注释中写了精度设置不影响statsd插件:
## By default, precision will be set to the same timestamp order as the
## collection interval, with the maximum being 1s.
## Precision will NOT be used for service inputs, such as logparser and statsd.
## Valid values are "ns", "us" (or "µs"), "ms", "s".
precision = ""

我还没有看到 precision 的设置在 statsd_input.conf文件。
实现这一目标的正确方法是什么?

最佳答案

不幸的是,influxdb 不支持此功能。解决方法是使用 socket_listener 发送信息。带有正确的时间戳。

此信息是 per the issues logged针对 influxdb 的 GitHub

关于influxdb - 如何设置telegraf statsd(influxdb)的时间精度?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53518429/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com