What is a DNS Lookup, and How Does It Relate To Your Internet?

WhatsApp Channel Join Now
What is Domain Name System (DNS) & How Does it Work? - Study CCNA

When you are browsing the web, do you ever think about how it’s all working? The internet is such a miraculous thing, but people seldom think about how it really works. 

For example, do you know what happens when you enter the URL of a website in your browser and it opens? The process is so fast, surely, it must be something really simple, right? Not exactly, in fact, a process called the DNS lookup happens. 

Today, we will explore what DNS is and how it relates to your internet experience. And you will learn how it ties into your browsing experience, online security, and other relevant things. Let’s begin.

What is a DNS Lookup?

DNS is an acronym. So you read it like D.N.S. The letters stand for “Domain Name System.” The DNS is basically a network of special servers called DNS servers, and they store crucial information about websites and domains.

The DNS is like a phone book. Each website/domain has an IP address, which is a sequence of numbers in a special format. This address identifies the exact location of a domain on the internet, kind of like a real address does for a house.

Now, humans can’t or don’t remember the individual IP addresses for all the websites they visit because that is just highly inconvenient. Instead, they remember the domain name, which is usually a human-friendly name like “Google” or “Apple” that they can easily remember. 

The problem is that computers and smartphones cannot use that to locate a website, because the name doesn’t provide that information. So, they go to the DNS, which translates the domain name into the correct IP address.

The process of going to a DNS server and making a request for the IP address of a domain is called the DNS lookup.

How Does a DNS Lookup Work?

So, how does the DNS lookup work? Let’s take a look. The process is quite simple, so you shouldn’t have any trouble understanding it. Let’s check it out step by step.

  1. You enter the domain name of a website in your browser’s address bar.
  2. Your device checks its DNS cache to see if it has data about the domain.
  3. If no data is found, the device pings a “DNS resolver.” A DNS resolver is a special DNS server whose role is to query the authoritative name servers to find the data about a domain. Your ISP provides it, but you can change it manually to use Google or Cloudflare’s resolver as well.
  4. The resolver checks its own cache for the data. If there is none, it queries the first server in the DNS hierarchy: the root nameserver. The root server has information about all the root-level domains. It either has the data or it knows which server has it.
  5. The resolver then queries the next server in the hierarchy: the Top Level Domain (TLD) server. It has information on all top-level domains such as “.com,” “.us,” “.gov,” “.edu,” etc. It either has the data or it sends the resolver to the next server that has it.
  6. The next and final server in the hierarchy is called the authoritative server. It has the complete data about a domain, and if it doesn’t, then the domain doesn’t exist.
  7. The resolver retrieves the data from the authoritative name server and provides it to your device.
  8. Your device learns the IP address of the website/domain and uses it to reach the right web server. 

As a result, your website gets loaded. All of that happens in milliseconds. To speed up the process, all servers in the hierarchy will store the information of the latest query in their cache. So, the DNS lookup completes faster due to finding the right data in the cache of the resolver or the first server.

If any part of the lookup process is slow, it makes your browsing experience feel terrible. That’s because, to the end user, any delay in DNS lookup will simply appear as a website taking too long to load.

How DNS Affects Your Internet Speed

Understanding the DNS lookup process should help you understand how it can affect your browsing speed. We have already seen one method of how browsing speed is affected; let’s check out some more.

  • Slow DNS. Delayed Page Loads: Even a 200ms delay in DNS resolution slows everything down.
  • Unresponsive DNS. Website Errors: If the DNS server fails to respond, you’ll see “DNS Probe Finished No Internet” or “Server Not Found” errors when trying to access a website.
  • Poor Routing or Geographic Lag. Some DNS resolvers may point you to servers in less optimal regions, increasing latency, which means that you get slower responses.

This is sometimes not the fault of the resolver but of the domain manager, who failed to provide enough DNS servers closer to your location. 

You can fix most of these errors by changing your DNS resolver. Many people notice an immediate uptick in their browsing speed by using Cloudflare or other third-party resolvers. However, some problems are at the domain end and can’t be fixed. But there are ways to determine if the problem is at your end or the website’s end.

How to Determine If the DNS Error Is On Your End Or the Website’s End?

Most people don’t think about DNS unless something goes wrong. But if a website refuses to load, your emails aren’t going through, or your internet feels slower than usual, then chances are you are not the problem.

Here’s how you can determine that.  

  1. First of all, make sure you are connected to the internet. 
  2. Do a speed test with an online tool such as wifispeed.io to check if your network speed is the issue.
  3. Then, try to open a different website to determine that you are not the cause of the DNS error.
  4. If different websites open, then refresh your browser DNS cache. A bad cache with outdated data can result in DNS-related errors and site inaccessibility.
  5. If, after doing all of that, you still can’t access a website, then check the propagation of its records. You can do that with an online tool such as Whatsmydns. To do that, simply enter the domain name in the tool and hit “Search.” 

If the domain is no longer active, you will get an error, and the propagation will show “Not Resolved.” A similar thing will happen if propagation is incomplete. At that point, you can be sure that the issue is on the website’s end and not yours.

Conclusion

The next time a website loads slowly or fails altogether, don’t just blame your Wi-Fi. Your DNS might be the real culprit. 

Troubleshooting for DNS errors will show you the truth. You can do that by using DNS lookups.

So, now you know what a DNS lookup is and how it relates to your internet.

Similar Posts