$
Learn Linux handbook
en
XP:0
Quest 77DNSMaster
+190 XP

DNS Resolution & Lookups (dig, nslookup & host)

Launch Interactive Terminal for This Quest→No installation required • Runs fully in browser

Concept & Overview

When your machine translates a human-readable domain name like example.com into an IP address like 93.184.216.34, it queries DNS nameservers configured in /etc/resolv.conf.

- /etc/resolv.conf: Contains your system's primary and fallback DNS nameservers.
- dig : The de-facto standard administrator tool for testing DNS queries, returning response headers, query latency, and record TTLs. Adding +short prints only the final IP answer.
- nslookup and host : Lightweight queries for checking A/AAAA and MX mail exchange records.

Inspect your local DNS resolvers with cat /etc/resolv.conf, run a DNS lookup using dig example.com (or dig +short example.com), and test name resolution using nslookup example.com (or host example.com).

Command Syntax Reference

Command / SyntaxDescription
cat /etc/resolv.confInspect configured system DNS resolvers
dig example.comQuery DNS records and server response headers
dig +short example.comQuery only resolved IP address
nslookup example.comInteractive and basic domain name resolution

Verification Objectives

These conditions will be automatically verified when you run commands inside the interactive terminal simulator:

  • ○
    Inspect /etc/resolv.conf
  • ○
    Query DNS records with dig
  • ○
    Resolve domain name with nslookup or host

Ready to complete Quest 77?

Test your skills live in the browser terminal with an emulated Linux filesystem, real-time command evaluation, and instant step-by-step hints.