文档文档

双写到 InfluxDB OSS 和 InfluxDB Clustered

如果您想在两个位置备份数据,或者您正在从 InfluxDB OSS 迁移到 InfluxDB Clustered,您可能需要设置 Telegraf 进行双写。

使用 Telegraf 同时写入 InfluxDB OSS 和 InfluxDB Clustered。

以下示例配置使用

使用以下配置将您的数据同时写入 OSS 和 Clustered 实例。

示例配置

# Include any other input, processor, or aggregator plugins that you want to include in your configuration.

# Send data to InfluxDB OSS v2
[[outputs.influxdb_v2]]
  ## The URLs of the InfluxDB instance.
  ##
  ## Multiple URLs can be specified for a single cluster, only ONE of the
  ## urls will be written to each interval.
  ## urls exp: http://127.0.0.1:9999
  urls = ["https://#:8086"]

  ## OSS token for authentication.
  token = "${INFLUX_TOKEN_OSS}"

  ## Organization is the name of the organization you want to write to. It must already exist.
  organization = "ORG_NAME_OSS"

  ## Destination bucket to write to.
  bucket = "BUCKET_NAME_OSS"

# Send data to InfluxDB cluster
 [[outputs.influxdb_v2]]
  ## The URLs of the InfluxDB instance.

  urls = ["https://cluster-host.com"]

  ## Cloud token for authentication.
  token = "${INFLUX_TOKEN}"

  ## For InfluxDB Clustered, set organization to an empty string.
  organization = ""

  ## Destination bucket to write into.
  bucket = "DATABASE_NAME"

此页内容对您有帮助吗?

感谢您的反馈!


Flux 的未来

Flux 即将进入维护模式。您可以继续像现在这样使用它,而无需对代码进行任何更改。

阅读更多

InfluxDB 3 开源版本现已发布公开 Alpha 版

InfluxDB 3 开源版本现已可用于 Alpha 测试,根据 MIT 或 Apache 2 许可获得许可。

我们正在发布两个产品作为 Alpha 版本的一部分。

InfluxDB 3 Core 是我们新的开源产品。它是用于时间序列和事件数据的最新数据引擎。InfluxDB 3 Enterprise 是一个商业版本,它建立在 Core 的基础上,增加了历史查询功能、读取副本、高可用性、可扩展性和细粒度的安全性。

有关如何开始使用的更多信息,请查看