目录
强大的性能,无限的扩展
收集、组织和处理海量高速数据。 当您将任何数据视为时序数据时,它都会更有价值。 借助 InfluxDB,这个排名第一的时序平台旨在与 Telegraf 一起扩展。
查看入门方法
输入和输出集成概述
Telegraf 的 Hashicorp Vault 插件允许从 Hashicorp Vault 服务收集指标,从而促进监控和运营洞察。
Graphite 插件使用户能够通过 TCP 将 Telegraf 收集的指标发送到 Graphite。 此集成允许使用 Graphite 的强大功能高效地存储和可视化时序数据。
集成详情
Hashicorp Vault
Hashicorp Vault 插件旨在从集群内运行的 Vault 代理收集指标。 它使 Telegraf(一种用于收集和报告指标的代理)能够与 Vault 服务接口,通常监听本地地址,例如 http://127.0.0.1:8200
。 此插件需要有效的令牌进行授权,以确保安全访问 Vault API。 用户必须直接配置令牌或提供令牌文件路径,从而增强身份验证方法的灵活性。 超时和可选 TLS 设置的正确配置进一步关系到指标收集过程的安全性和响应性。 由于 Vault 是管理密钥和保护敏感数据的关键工具,因此通过此插件监控其性能和运行状况对于维护运营安全和效率至关重要。
Graphite
此插件通过原始 TCP 将指标写入 Graphite,从而允许将 Telegraf 收集的指标无缝集成到 Graphite 生态系统中。 使用此插件,用户可以配置多个 TCP 端点以进行负载均衡,从而确保指标传输的高可用性和可靠性。 使用前缀自定义指标命名以及利用各种模板选项的能力增强了数据在 Graphite 中表示方式的灵活性。 此外,对 Graphite 标签的支持以及严格清理指标名称的选项允许进行强大的数据管理,以满足用户不同的需求。 此功能对于希望利用 Graphite 强大的指标存储和可视化功能,同时保持对数据表示控制的组织至关重要。
配置
Hashicorp Vault
[[inputs.vault]]
## URL for the Vault agent
# url = "http://127.0.0.1:8200"
## Use Vault token for authorization.
## Vault token configuration is mandatory.
## If both are empty or both are set, an error is thrown.
# token_file = "/path/to/auth/token"
## OR
token = "s.CDDrgg5zPv5ssI0Z2P4qxJj2"
## Set response_timeout (default 5 seconds)
# response_timeout = "5s"
## Optional TLS Config
# tls_ca = /path/to/cafile
# tls_cert = /path/to/certfile
# tls_key = /path/to/keyfile
Graphite
# Configuration for Graphite server to send metrics to
[[outputs.graphite]]
## TCP endpoint for your graphite instance.
## If multiple endpoints are configured, the output will be load balanced.
## Only one of the endpoints will be written to with each iteration.
servers = ["localhost:2003"]
## Local address to bind when connecting to the server
## If empty or not set, the local address is automatically chosen.
# local_address = ""
## Prefix metrics name
prefix = ""
## Graphite output template
## see https://github.com/influxdata/telegraf/blob/master/docs/DATA_FORMATS_OUTPUT.md
template = "host.tags.measurement.field"
## Strict sanitization regex
## This is the default sanitization regex that is used on data passed to the
## graphite serializer. Users can add additional characters here if required.
## Be aware that the characters, '/' '@' '*' are always replaced with '_',
## '..' is replaced with '.', and '\' is removed even if added to the
## following regex.
# graphite_strict_sanitize_regex = '[^a-zA-Z0-9-:._=\p{L}]'
## Enable Graphite tags support
# graphite_tag_support = false
## Applied sanitization mode when graphite tag support is enabled.
## * strict - uses the regex specified above
## * compatible - allows for greater number of characters
# graphite_tag_sanitize_mode = "strict"
## Character for separating metric name and field for Graphite tags
# graphite_separator = "."
## Graphite templates patterns
## 1. Template for cpu
## 2. Template for disk*
## 3. Default template
# templates = [
# "cpu tags.measurement.host.field",
# "disk* measurement.field",
# "host.measurement.tags.field"
#]
## timeout in seconds for the write connection to graphite
# timeout = "2s"
## Optional TLS Config
# tls_ca = "/etc/telegraf/ca.pem"
# tls_cert = "/etc/telegraf/cert.pem"
# tls_key = "/etc/telegraf/key.pem"
## Use TLS but skip chain & host verification
# insecure_skip_verify = false
输入和输出集成示例
Hashicorp Vault
-
集中式密钥管理监控:利用 Vault 插件监控分布式系统中的多个 Vault 实例,从而实现密钥访问模式和系统运行状况的统一视图。 此设置可以帮助 DevOps 团队快速识别密钥访问中的任何异常,从而深入了解不同环境中的安全态势。
-
审计日志集成:配置此插件以将监控指标馈送到审计日志系统,使组织能够全面了解其 Vault 交互。 通过将审计日志与指标相关联,团队可以更有效地调查问题、优化性能并确保符合安全策略。
-
部署期间的性能基准测试:在与 Vault 交互的应用程序部署期间,使用此插件监控这些部署对 Vault 性能的影响。 这使工程团队能够了解更改如何影响密钥管理工作流程,并主动解决性能瓶颈,从而确保平稳的部署流程。
-
阈值超限警报:将此插件与警报机制集成,以便在指标超出预定义阈值时通知管理员。 这种主动监控可以帮助团队快速响应潜在问题,通过允许团队在任何严重事件发生之前采取措施来维护系统可靠性和正常运行时间。
Graphite
-
动态指标可视化:Graphite 插件可用于将来自各种来源(例如应用程序性能数据或服务器运行状况指标)的实时指标馈送到 Graphite。 这种动态集成使团队能够创建交互式仪表板,以可视化关键绩效指标、跟踪长期趋势并做出数据驱动的决策以提高系统性能。
-
负载均衡指标收集:通过在插件中配置多个 TCP 端点,组织可以实现指标传输的负载均衡。 此用例确保指标交付既有弹性又高效,降低了高流量期间数据丢失的风险,并保持了向 Graphite 的可靠信息流。
-
自定义指标标记:借助对 Graphite 标签的支持,用户可以利用 Graphite 插件来增强其指标的粒度。 使用相关信息(例如应用程序环境或服务类型)标记指标,可以进行更精细的查询和分析,使团队能够深入研究特定感兴趣的领域,以获得更好的运营洞察。
-
增强的数据清理:利用插件的严格清理选项,用户可以确保其指标名称符合 Graphite 的要求。 这种主动措施消除了指标名称中无效字符引起的潜在问题,从而实现更简洁的数据管理和更准确的可视化。
反馈
感谢您成为我们社区的一份子! 如果您有任何一般性反馈或在这些页面上发现任何错误,我们欢迎并鼓励您提供意见。 请在 InfluxDB 社区 Slack 中提交您的反馈。
强大的性能,无限的扩展
收集、组织和处理海量高速数据。 当您将任何数据视为时序数据时,它都会更有价值。 借助 InfluxDB,这个排名第一的时序平台旨在与 Telegraf 一起扩展。
查看入门方法