Skip to content

Instantly share code, notes, and snippets.

@rvdheij
Created June 30, 2020 18:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rvdheij/3889b9cd0b3e08663bd1ce819bff78b5 to your computer and use it in GitHub Desktop.
Save rvdheij/3889b9cd0b3e08663bd1ce819bff78b5 to your computer and use it in GitHub Desktop.
[rvdheij@lnxz16 ~]$ export INFLUX_TOKEN=j7qMwLtV7lzpreO9Opw5e6jm.....
[rvdheij@lnxz16 ~]$ telegraf --config https://eu-central-1-1.aws.cloud2.influxdata.com/api/v2/telegrafs/05e59166e9ebd000
2020-06-30T18:21:22Z I! Starting Telegraf 1.14.4
2020-06-30T18:21:29Z I! Loaded inputs: swap system cpu disk diskio mem net processes
2020-06-30T18:21:29Z I! Loaded aggregators:
2020-06-30T18:21:29Z I! Loaded processors:
2020-06-30T18:21:29Z I! Loaded outputs: influxdb_v2
2020-06-30T18:21:29Z I! Tags enabled: host=lnxz16
2020-06-30T18:21:29Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"lnxz16", Flush Interval:10s
^C2020-06-30T18:23:06Z I! [agent] Hang on, flushing any cached metrics before shutdown
[rvdheij@lnxz16 ~]$ telegraf --config sample.conf
2020-06-30T18:27:49Z I! Starting Telegraf 1.14.4
2020-06-30T18:27:49Z I! Loaded inputs: swap system cpu disk diskio mem net processes
2020-06-30T18:27:49Z I! Loaded aggregators:
2020-06-30T18:27:49Z I! Loaded processors:
2020-06-30T18:27:49Z I! Loaded outputs: influxdb_v2
2020-06-30T18:27:49Z I! Tags enabled: host=lnxz16
2020-06-30T18:27:49Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"lnxz16", Flush Interval:10s
2020-06-30T18:28:05Z E! [outputs.influxdb_v2] when writing to [https://eu-central-1-1.aws.cloud2.influxdata.com]: Post https://eu-central-1-1.aws.cloud2.influxdata.com/api/v2/write?bucket=moncoll-vmy&org=rvdheij%40gmail.com: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
2020-06-30T18:28:05Z E! [agent] Error writing to outputs.influxdb_v2: Post https://eu-central-1-1.aws.cloud2.influxdata.com/api/v2/write?bucket=moncoll-vmy&org=rvdheij%40gmail.com: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
@rvdheij
Copy link
Author

rvdheij commented Jun 30, 2020

[rvdheij@lnxz16 ~]$ grep -v '^ *#' < sample.conf | grep -v '^$'
[agent]
  interval = "10s"
  round_interval = true
  metric_batch_size = 1000
  metric_buffer_limit = 10000
  collection_jitter = "0s"
  flush_interval = "10s"
  flush_jitter = "0s"
  precision = ""
  debug = false
  quiet = false
  logfile = ""
  hostname = ""
  omit_hostname = false
[[outputs.influxdb_v2]]	
  urls = ["https://eu-central-1-1.aws.cloud2.influxdata.com"]
  token = "$INFLUX_TOKEN"
  organization = "rvdheij@gmail.com"
  bucket = "moncoll-vmy"
[[inputs.cpu]]
  percpu = true
  totalcpu = true
  collect_cpu_time = false
  report_active = false
[[inputs.disk]]
  ignore_fs = ["tmpfs", "devtmpfs", "devfs", "overlay", "aufs", "squashfs"]
[[inputs.diskio]]
[[inputs.mem]]
[[inputs.net]]
[[inputs.processes]]
[[inputs.swap]]
[[inputs.system]]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment