Domain Name System(DNS)

What is DNS

Think of it as the internet’s phone book. It translates human-friendly domain names like google.com into numerical IP addresses (e.g., 123.123.255.255) that computers use to locate each other. Without DNS, we’d be stuck memorizing strings of numbers to visit websites.

How DNS Works

When you type a URL into your browser, DNS steps in to resolve that name into an IP address. Your request gets routed to the right server, and the website loads. This process is fast, decentralized, and hierarchical, ensuring the internet stays organized and accessible. The Internet Corporation for Assigned Names and Numbers (ICANN) oversees this system, managing domain names’ coordination and security.

ICANN vs. Domain Registrars

So, who decides which domain belongs to whom? ICANN acts like the “mall management” of the internet, setting the rules, while domain registrars (e.g., GoDaddy, Google Domains) are the “store lease providers.” You don’t buy a domain directly from ICANN. Instead, you go through a registrar accredited by them. They handle the registration, ensuring your domain is officially yours.

DNS Records

DNS relies on records to store domain info. The most common is the A (Address) record, linking a domain to an IP address. When you visit a site, the DNS server checks this record to direct your request. If the server’s IP is static, your computer might cache it for faster access next time.

Breaking Down a URL

for ex) https://www.google.com/hello:

  • Protocol (HTTPS): Defines how data is transferred (securely, in this case).
  • Subdomain (domains): A specific section of the site.
  • Primary Domain (google.com): The core identity you register.
  • Top-Level Domain (.com): Classifies the site (commercial, in this case).
  • Path (/hello): Points to a specific page or resource.

Ports can also appear (e.g., :8080), but for standard HTTP (port 80) or HTTPS (port 443), they’re usually implied.

Why It Matters

DNS ensures requests hit the right servers efficiently, tying together clients, servers, and the broader internet.


Comments

Popular posts from this blog

@ModelAttribute vs @RequestBody in Validation

Side Project(a self-imposed 3-day "Hackathon" challenge)

Google: The King is Back