Fun with DNS: Three Useful Commands

The DNS is a distributed, hierarchical database where authority flows from the top (or root) of the hierarchy downward.

When thinking of the structure of the DNS, imagine an inverted tree. Each branch of the tree is within a zone of authority; however, multiple branches of the tree can be within a single zone.

The software (Bind being the most common) that stores domain name information is called a domain name server. A single name server can be authoritative for multiple zones. All zones have a primary master and a secondary master name server that provides authoritative responses for their zones.

If you query a name server not authoritative for a particular zone, that name server will most likely have up-to-date information. This is because zone information propagates throughout the Internet at regular intervals, and name servers cache zone information for which they are not authoritative.

DNS Commands

There are three crucial commands that can put all the DNS information you need at your fingertips. The way to use this article is to try each of the commands listed on a domain name, so you can see what the output looks like. Learn by doing!

Zone file database records divide DNS information into three primary types: NS (Name Server) records, MX (Mail Exchange) records, and A (Address) records. NS records indicate the name servers. MX records indicate the hosts that handle e-mail delivery; the priority (pri) number indicates the order in which mail servers are used, with the lowest number receiving the highest priority. The A (Address) records map hostnames to IP addresses, the real names of machines.

host

This is the simplest of the DNS commands. It is a quick way to determine the IP address of a hostname:

: host www.your-domain-name.com

The -a option will return all of the DNS information in verbose format.

: host -a www.your-domain-name.com

Now that you know the IP address for www.your-domain-name.com, try a reverse lookup.

: host IP-ADDRESS

dig (domain information groper)

This command gathers and returns DNS information in a format the name server can use directly. You will find it easy to query specific name servers with dig.

You can quickly determine the Name servers of your host or any other host:

: dig ns your-host.com

Then you check your (or another) website against the host's name servers:

: dig www.your-domain-name.com @ns.your-host.com

Dig can provide output that is in the same format as the zone file itself. Here is how to get the whole zone file:

: dig any your-domain-name.com

Here are the most useful dig query types: dig any (gathers all DNS information), dig ns (gathers name server information), dig mx (gathers mail exchanger information) and dig a (gathers network address information).

The dig command can also do reverse lookups with output formatted for the zone file:

: dig -x IP-Address

nslookup

You can use this tool as a single line command, or you can use it interactively, which distinguishes it from the other DNS commands. Once you have started nslookup, type set all to list the default options. As with dig you can choose the server (name server) you want to query, and you can decide the type of DNS information on which to focus.

Just as you can issue commands to nslookup interactively, you can also change the initial defaults by starting a .nslookuprc file. The format of the .nslookup is one command per line:

set type=NS
set domain=srvns.your-host.com
set timeout=10

Conclusion

These three commands can provide you with most of the information you need about your domain names. They are powerful tools, and this article should provide you enough information to get started or offer a quick refresher if you already use these commands.

About the Author:

Dan Forootan founded ez publishing, inc. in 1998. EZ Publishing's ez publishing, inc. provides the essential tools for using the Web as a marketing tool. The package includes web hosting, the ez publishing, inc. solution. Please email questions or comments about this article to ez publishing, inc.. Thank you.

affordable house cleaning Wilmette ...
In The News:

A phishing email disguised as an Evite fooled a man even after he emailed his friend to verify it, revealing how compromised Gmail accounts aid scams.
Microsoft's AI diagnostic system identified 83% of complex medical cases in a study, more than doubling the 36% accuracy of generalist doctors.
Account takeover threats go beyond stolen passwords as criminals exploit session cookies, SIM swaps and MFA fatigue to bypass your login security.
SpaceX is reportedly pursuing access to 80,000 cell sites to turn Starlink into a major wireless carrier rivaling Verizon, AT&T and T-Mobile.
Tech advocacy groups warn that foreign nationals at AI companies like OpenAI and Google pose a national security threat amid a lack of federal oversight.
Singapore researchers built the world's first touchscreen woven into clothing, surviving 50 machine washes while displaying images and responding to touch.
The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
A startup founder woke to $449 in unexpected OpenAI and Anthropic charges after stolen API keys were exploited during the "Black October" cyber wave.
Educational Testing Service hackers stole millions of California student records, but families who moved out of state years ago may also be affected.
Apple's iPhone Duo screens are cracking near the hinge just days after its $1,999 launch, and iFixit's CT scans may reveal what's going wrong.
Travel expert Katy Nastro says 50,000 American Airlines AAdvantage miles vanished from her account after someone redeemed them without permission.
Google AI Overviews can't be permanently turned off, but adding -AI to your searches and using the built-in Web filter can help bypass AI summaries.
Attaxion researchers found 30 fake Texas campaign merchandise stores traced to just two sellers hawking gear for competing Republicans and Democrats.
GM plans to debut eyes-off driving in the Cadillac Escalade IQ by 2028, but safety testing reveals how long distracted drivers take to regain control.
Data brokers assign labels predicting your health, finances and religion based on browsing and purchases, then sell those profiles to businesses.
Elon Musk says he'll give one SpaceX share to every kid in America in 2027, but key details about eligibility and distribution remain unclear.
ClearSpace UK's robotic spacecraft with giant claws will chase down dead satellites at 17,000 mph, with a 2029 launch from Scotland planned.
A fake Social Security statement phishing email uses the SSA logo and a convincing layout, but the sender's domain instantly exposes the scam.
A clean credit report doesn't mean your identity is safe. Six ways criminals can steal from you without triggering a credit monitoring alert.
Carolyn Marvin, a 78-year-old retired professor, was arrested after blocking an Uber Eats delivery robot on a Philadelphia sidewalk for months.
The Midnight Mimosa malware campaign hides inside cheap Android phone firmware, giving attackers powerful access before owners even turn devices on.
The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
Meta's Muse AI was built to manage tasks, but users are developing romantic AI relationships and even calling the AI companion their girlfriend.
A Minnesota murder suspect's notebook listed 11 people search websites, raising urgent questions about data broker opt-out and online privacy risks.
Google Universal Cart tracks price drops, surfaces promo codes and uses Google Wallet to match your best credit card rewards before checkout.

How to Choose a Web Hosting Company?

Nowadays, anybody can afford to order a feature-packed web hosting... Read More

Effectiveness of Web Hosting Directories (WHDs)

John is very happy today, for the first time in... Read More

Unique Features that Leading Web Hosts are Now Offering

Some web hosts are offering more than others for the... Read More

Managed Hosting

Managed hosting is a dedicated server that is accompanied by... Read More

The 2 Sides of Reseller Web Hosting

In the first case the customer is really looking for... Read More

Low Cost Web Hosting Services ? Dont Forget About Uptime

Once you have your company's web site up and running,... Read More

Steps to Becoming a Web Host Reseller

You've decided to get a reseller web hosting account to... Read More

Budget Web Hosting - Dirty Secrets That Can Squash Your Websites Chance of Success

When it comes to budget web hosting, there are a... Read More

What is a Web Host Reseller Account?

A web host reseller account is a web hosting account... Read More

Good Web Hosting ? What Is It?

With hundreds of web hosting companies to choose from today... Read More

Managed Hosting Services - Who Benefits from It?

Managed Hosting Services are used primarily by companies that either... Read More

How Can I Get The Web Host Services And Support I Need, Hassle-free?

Choosing a host or switching hosts can be an agonizing... Read More

Finding a Home for Your Internet Enterprise - A Point by Point List

After much Net surfing and looking at all the offers... Read More

Cheap Internet Hosting - Get The Most For Your Money With a Cheap Web Hosting Package

With so many web hosting companies competing for your web... Read More

Website Sitebuilders: Easy to use Website builders Come with a Price

Professional web designers don't come cheap. A good web designer... Read More

Choosing Your Web Hosting Reseller Software

As a web host reseller, one of your most important... Read More

Virtual Private Servers (VPS) Web Hosting

A Virtual Private Server (VPS), also referred to as Virtual... Read More

Reseller Hosting: The Good and The Bad!

Reseller webhosting can be a great way to earn some... Read More

Free Web Hosting

There is no concept of free lunch in the world,... Read More

CHMOD - Undertanding File Permissions on a Unix-Based Server

The basic command for changing file permissions in unix based... Read More

CGI Web Hosting ? 3 Essential Scripts for Your Business

If there's one thing that people love it is a... Read More

Web Hosting: Shared or Dedicated - Which Should You Choose?

Before you begin your search for a web host you... Read More

What Is Web Hosting?

The best way to explain this is by comparing it... Read More

Buyer Beware: Web Hosting, Registration, and Site Building All in One Package Nightmares

Starting out in any type of online marketing or Internet... Read More

Finding the Right Web Host

Choosing the right Web Hosting service for your website can... Read More

weekly home cleaning Arlington Heights ...