DNS Check

Supported OS Linux Mac OS Windows

Integration version3.3.0

Overview

Monitor the resolvability of and lookup times for any DNS records using nameservers of your choosing.

Setup

Installation

The DNS check is included in the Datadog Agent package. No additional installation is needed on your server.

Though many metrics-oriented checks are best run on the same host(s) as the monitored service, you may want to run this status-oriented check from hosts that do not run the monitored DNS services.

Configuration

  1. Edit the dns_check.d/conf.yaml file, in the conf.d/ folder at the root of your Agent’s configuration directory to start collecting your DNS data. See the sample dns_check.d/conf.yaml for all available configuration options:

    init_config:
    
    instances:
      ## @param name - string - required
      ## Name of your DNS check instance.
      ## To create multiple DNS checks, create multiple instances with unique names.
      #
      - name: '<INSTANCE_NAME>'
    
        ## @param hostname - string - required
        ## Hostname to resolve.
        #
        hostname: '<HOSTNAME>'
    

    If you omit the nameserver option, the check uses whichever nameserver is configured in local network settings.

  2. Restart the Agent to begin sending DNS service checks and response times to Datadog.

Validation

Run the Agent’s status subcommand and look for dns_check under the Checks section.

Data Collected

Metrics

dns.response_time
(gauge)
The response time for DNS query for a given record, tagged by hostname, e.g. 'hostname:example.com'.
Shown as second

Events

The DNS check does not include any events.

Service Checks

dns.can_resolve
Returns Critical if DNS resolution times out or fails, OK otherwise. .
Statuses: ok, critical

Troubleshooting

Need help? Contact Datadog support.

PREVIEWING: alai97/reorganize-some-sections-in-dora-metrics