Evan Harmon - Memex

DNS

The Domain Name System (DNS) is a hierarchical and distributed naming system for computers, services, and other resources in the Internet or other Internet Protocol (IP) networks. It associates various information with domain names assigned to each of the associated entities. Most prominently, it translates readily memorized domain names to the numerical IP addresses needed for locating and identifying computer services and devices with the underlying network protocols. The Domain Name System has been an essential component of the functionality of the Internet since 1985.
wikipedia:: Domain Name System

Meta

  • Domain Name System
  • A namespace - one of the two principal namespaces of the Internet (the other is IP addresses).
  • Namespaces
  • Distributed/decentralized and fault-tolerant
  • Successor to ARPANET’s HOSTS.TXT file
  • Allows for a single domain name to be translated to different things for different users depending on, e.g., proximity - i.e., one website can be fast due to it being distributed to multiple servers on the Internet.
  • Technically distinct from a domain name server or just name server
    • Which is a computer application that uses/does DNS - i.e., the name server is the server component of the domain name system
  • Hierarchy goes from rightmost to left, going from top/highest level, down
  • Not case sensitive, so Google.com == google.com
  • The DNS database is traditionally stored in a structured text file, the zone file, but other database systems are common.
  • BIND is most widely used DNS software

Confusion of Multi-word Domains

  • e.g. whorepresents.com, expertsexchange.com
  • Sometimes clarified by camelCase or Intercapping as in WhoRepresents.com
  • Sometimes clarified by a hyphen as in experts-exchange.com

/etc/resov.conf

- lists your dns server

Domain name

  • The labels are what follow the TLD. A label can be anything, from one letter to a full sentence. The label located right before the TLD can also be referred as a Secondary Level Domain (SLD). A domain name can have many labels (or components), it is not mandatory nor necessary to have 3 labels to form a domain name.
  • DNS Root .
    • Unnamed, expressed as the empty label terminated by the dot ., if necessary in technical situations such as ?FQDNs? or ?DNS Zones?
  • gTLDs
    • Top-level domains with three or more characters
  • TLDs
    • Top-Level Domain
    • Now over 1000 TLDs
    • .com
    • .org
    • .edu
    • .gov
    • .net
    • .info
    • .io
  • ccTLD
    • Country Code Top-Level Domain
    • .us
    • .uk
      • Second Level Domains: .co.uk or .gov.uk
    • .fr
    • .de
    • .jp
  • IDN ccTLD
    • internationalized country code top-level domains
    • ccTLDs in non-Latin character sets (e.g., Arabic or Chinese)
  • Second-level Domain
  • Subdomain
  • Canonical Domain Name
    • a record in a DNS database that indicates the true, or canonical, host name of a computer that its aliases are associated with. E.g., with www.example.com and example.com the canonical name can be specified as the “real” version/domain name.
    • Done with CNAME record
  • FQDN
  • Hostname
    • https://en.wikipedia.org/wiki/Hostname
    • A domain name that is associated with an IP address can be called a hostname
    • Or the local name of a computer, regardless of DNS, can also be called a hostname
    • Or a local name of a computer, if setup as a FQDN, e.g. as in setting up Windows Server - hostname.companywebsite.com is a FQDN built with the local hostname
  • DNS Server Addresses
    • Local client
    • Routers

DNS Lookup

  • There are actually DNS caches at every hierarchy of the "lookup" process that ultimately gets your computer to load the website. The computer reaches your router, which contacts your ISP, which might hit another ISP before ending up at what's called the "root DNS servers." Each of those points in the process has a DNS cache for the same reason, which is to speed up the name resolution process.

DNS Refreshing

  • DNS databases are stored on every DNS server worldwide, and all these servers refer to a few ones called “authoritative name server” or “top-level DNS servers.” Whenever your registrar creates or updates any information for a given domain, the information must be refreshed in every DNS database. Each DNS server that knows about a given domain stores the information for some time before it is automatically invalidated and then refreshed (the DNS server queries an authoritative server again). Thus, it takes some time for DNS servers that know about this domain name to get the up-to-date information.
  • Authoritative Name Servers/Top-Level DNS Servers

DNS Local Cache

  • a temporary database, maintained by a computer's operating system, that contains records of all the recent visits and attempted visits to websites and other internet domains. In other words, a DNS cache is just a memory of recent DNS lookups that your computer can quickly refer to when it's trying to figure out how to load a website.
  • Difference between local DNS cache and a client's hosts file?
  • Checked before checking remote/public DNS servers
  • Windows: ipconfig /displaydns
  • Flush DNS Cache
    • Windows: ipconfig /flushdns
    • macOS: dscacheutil -flushcache
    • Linux: /etc/rc.d/init.d/nscd restart
    • Reboot Router

DNS Records

  • Time-To-Live (TTL)
    • how frequently a resource record should be refreshed.

A Record

  • Returns a 32-bit IPv4 address, most commonly used to map hostnames to an IP address of the host

AAAA Record

  • Used to map hostnames to IP6 address of the host

CNAME Record

  • https://en.wikipedia.org/wiki/CNAME\_record
  • A type of resource record in the Domain Name System (DNS) which maps one domain name to another.
  • CNAME records must always point to another domain name, never directly to an IP address
  • Contra Ax

SOA Record

  • A Start of Authority record (abbreviated as SOA record) is a type of resource record in the Domain Name System (DNS) containing administrative information about the zone, especially regarding zone transfers.

MX Record

  • specifies a mail server responsible for accepting email messages on behalf of a recipient's domain, and a preference value used to prioritize mail delivery if multiple mail servers are available. The set of MX records of a domain name specifies how email should be routed with the Simple Mail Transfer Protocol (SMTP).

NS Record

  • Delegates a DNS zone to use the given authoritative name servers

DNS Lookup

DNS Reverse Lookup or PTR

  • In computer networks, a reverse DNS lookup or reverse DNS resolution (rDNS) is the querying of the Domain Name System (DNS) to determine the domain name associated with an IP address – the reverse of the usual "forward" DNS lookup of an IP address from a domain name. The process of reverse resolving an IP address uses PTR records. The reverse DNS database of the Internet is rooted in the arpa top-level domain.

DNS Servers

  • 8.8.8.8

Sources

Inbox

DNS
Interactive graph
On this page
DNS
Meta
Confusion of Multi-word Domains
Hosts (file)
/etc/resov.conf
dnsmasq
Domain name
DNS zone
BIND
Domain Registration
DNS Lookup
DNS Refreshing
DNS Local Cache
DNS Records
A Record
AAAA Record
CNAME Record
SOA Record
MX Record
NS Record
DNS Lookup
DNS Reverse Lookup or PTR
Dynamic DNS
DNS Servers
Codex/Tech/Google DNS
OpenDNS
Cloudflare
Pi-hole
DNSSEC
DoH
CoreDNS
Sources
Inbox