# Global tags can be specified here in key="value" format.
[global_tags]
  # dc = "us-east-1" # will tag all metrics with dc=us-east-1
  # rack = "1a"
  ## Environment variables can be used as tags, and throughout the config file
  # user = "$USER"


# Configuration for telegraf agent
[agent]

  #enabled = true
  interval = "15s"
  round_interval = false
  metric_batch_size = 1000
  metric_buffer_limit = 10000
  collection_jitter = "2s"
  
  #interval = "10s"
  #round_interval = true
  #metric_batch_size = 1000
  #metric_buffer_limit = 10000
  #collection_jitter = "0s"
  
  flush_interval = "10s"
  flush_jitter = "0s"
  precision = "1us"
  debug = true
  quiet = false
  hostname = ""
  omit_hostname = false
  
  
  #debug = true
  #quiet = false
  logtarget = "file"
  logfile = "/dev/shm/telegraf.log"
  logfile_rotation_max_archives=5
  logfile_rotation_max_size="5MB"  


### OUTPUT

##########################
### our local database ###
##########################

[[outputs.influxdb]]
  
  urls = ["http://127.0.0.1:8086"]
  database = "zfsb"

  #interval = "5s"

  ## Retention policy to write to. Empty string writes to the default rp.
  retention_policy = ""
  ## Write consistency (clusters only), can be: "any", "one", "quorum", "all"
  write_consistency = "any"

  ## Write timeout (for the InfluxDB client), formatted as a string.
  ## If not provided, will default to 5s. 0s means no timeout (not recommended).
  timeout = "5s"
  username = "rio"
  password = "rio"
  ## Set the user agent for HTTP POSTs (can be useful for log differentiation)
  # user_agent = "telegraf"
  ## Set UDP payload size, defaults to InfluxDB UDP Client default (512 bytes)
  # udp_payload = 512

  [outputs.influxdb.tagdrop]
    influxdb_database = ["*"]



[[inputs.exec]]
  ## Commands array
  commands = ["/myshell/backup_telegraf"]

  ## Timeout for each command to complete.
  timeout = "30s"
  interval = "15s"
  data_format = "influx"

