telegraf/plugins/inputs/dns_query
Lee Jaeyong 7d97ae6421 Query servers in parallel in dns_query input (#4754) 2018-09-27 17:26:36 -07:00
..
README.md Don't report 0ms on timeout in dns_query (#4118) 2018-05-07 18:18:01 -07:00
dns_query.go Query servers in parallel in dns_query input (#4754) 2018-09-27 17:26:36 -07:00
dns_query_test.go use AddError everywhere (#2372) 2017-04-24 11:13:26 -07:00

README.md

DNS Query Input Plugin

The DNS plugin gathers dns query times in miliseconds - like Dig

Configuration:

# Query given DNS server and gives statistics
[[inputs.dns_query]]
  ## servers to query
  servers = ["8.8.8.8"]

  ## Network is the network protocol name.
  # network = "udp"

  ## Domains or subdomains to query.
  # domains = ["."]

  ## Query record type.
  ## Posible values: A, AAAA, CNAME, MX, NS, PTR, TXT, SOA, SPF, SRV.
  # record_type = "A"

  ## Dns server port.
  # port = 53

  ## Query timeout in seconds.
  # timeout = 2

Metrics:

  • dns_query
    • tags:
      • server
      • domain
      • record_type
      • result
    • fields:
      • query_time_ms (float)
      • result_code (int, success = 0, timeout = 1, error = 2)

Example Output:

dns_query,domain=mjasion.pl,record_type=A,server=8.8.8.8 query_time_ms=67.189842 1456082743585760680