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.

Airbnb cleaning service Glenview ..
In The News:

Apple releases emergency patches for two zero-day vulnerabilities actively exploited in attacks. iPhone and iPad users urged to update immediately.
DoorDash launches Zesty, an AI-powered social app that recommends restaurants through conversational search, now testing in San Francisco and New York.
Cybersecurity firm Infoblox reveals that over 90 percent of parked domains now redirect visitors to scams and malware, making simple typos extremely dangerous.
The Fox News AI Newsletter covers the latest artificial intelligence technology advancements, including the challenges and opportunities AI presents now and for the future.
GPT-5.2 is now live for all ChatGPT users with improved coding, writing and image interpretation, with Kurt Knutsson offering his review.
New iPhone replacement scam uses pressure tactics and fake carrier calls to steal devices from buyers. Criminals claim shipping errors and demand urgent returns.
Amazon Ring's new facial recognition feature sparks privacy controversy as Electronic Frontier Foundation critics argue the AI upgrade expands surveillance risks.
New Android banking trojan Sturnus steals credentials, reads encrypted messages and controls devices.
Denmark's 3D-printed student village proves automation builds 36 apartments faster than traditional methods. Skovsporet project shows housing future.
Discover Android's new Sound Notifications feature that alerts you to smoke alarms, doorbells, and baby cries even when wearing headphones.
New SantaStealer malware reportedly threatens holiday shoppers with password theft. This Christmas-themed info-stealer targets browsers and crypto wallets.
The Christmas season brings a surge in Netflix phishing scams targeting shoppers with fake emails. Stacey P received convincing scam but verified account first.
San Francisco Giants invite Jamie Grohsong to throw ceremonial first pitch at Oracle Park after he learned to play baseball with a bionic hand following an injury.
FBI warns cybercriminals are stealing family photos from social media to create fake proof of life images in virtual kidnapping scams targeting victims.
Instagram's new 'Your Algorithm' tool lets you control your Reels feed in real time. The app now gives you power to customize what videos you see.
Major Marquis fintech breach exposes 400,000-plus Americans' data through unpatched SonicWall vulnerability, with Texas hardest hit at 354,000 affected.
Free up iPhone storage fast by clearing large photos and videos from Messages app. Simple steps for iOS users to delete attachments without losing chats.
Scammers are flooding inboxes with fake tracking alerts that mimic real carriers, exploiting the holiday rush to steal logins and personal data.
The Fox News AI Newsletter brings you the latest news on AI technology advancements and the challenges and opportunities AI presents now and for the future.
Texas family reunites with missing 11-year-old cat Grayson after 103 days using Petco Love Lost's AI photo matching technology and community help.
Tired of AI customer service loops? These insider tricks help you escape "frustration AI" and get real human help when you need it most for urgent issues.
Unlock richer audio from your streaming apps with simple tweaks to volume normalization, equalizer settings, and quality preferences for cleaner sound.
Scammers are sending fake Facebook settlement payout emails that mimic legitimate notices from the privacy settlement administrator to deceive users.
Holiday shopping scams surge as fake refund emails target distracted consumers during Black Friday and holiday seasons, costing Americans billions annually.
The AI-powered IRMO M1 exoskeleton features four modes, including turbo, eco, training and rest for hiking, running, cycling and sports with eight-hour battery life.

Finding a Reliable Host

Finding reliable hosting for your business opportunity is no small... Read More

The Top 10 Essential Ingredients of Every Linux Hosting Plan (Package)

Any website comprises the following ? Domain name, Webspace, Webpages.Lets... Read More

How to Find a Dependable Web Host

Your new website is ready to upload, and now you... Read More

Linux vs. Windows Web Hosting, Does It Make A Difference?

One of the most confusing decisions someone new to web... Read More

Top 6 Ways to Promote Your Web Hosting Business Part 1

Promoting a new company in the crowded industry of web... Read More

Finding the Right Web Host

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

Cheap Web Hosting, What To Look For And What To Stay Away From

"Bargains for sale, Unlimited Hosting for only a Dollar.""Get your... Read More

How to Choose the Web Site Hosting Service thats Right for You

There are few things as critical to your e-business success... Read More

Hosting Options for an Ecommerce Web Site

Deciding how to host your ecommerce Web site and what... Read More

Solving Common Problems with Hosting Companies

For those of you with Web sites, you probably know... Read More

Free Web Hosting - Why Might It Be A Bad Idea

When talking about free anything the legitimate question that first... Read More

Unlimited Wealth Creation Through Reseller Hosting

Web hosting can be an exciting business start up for... Read More

Choosing a Right Hosting Solution

You must have done all the hard works for developing... Read More

UNIX vs. Windows- What Server Operating System Should You Use for Your Web Hosting?

So you've decided to create a website? The most obvious... Read More

Dedicated Web Hosting : The Executive Summary

What is Dedicated Web Hosting? Dedicated web hosting can alleviate... Read More

Confessions and Tips from a Top Web Hosting Salesman

Have you ever gone car shopping with a former car... Read More

Choosing the Perfect Deluxe Web Site Hosting Plan

If you are looking for a deluxe web site hosting... Read More

Benefits of Web Hosting and Choice of a Web Host

Well let me start this way, a lot of people... 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

How to Choose a Hosting Web Package Cheap

If you're looking for a hosting web package cheap there... Read More

Web Hosting: Which Is The Host With The Most?

So you want to publish a web site do you?... Read More

Switching Web Host

Moving a web site to a new host is not... Read More

Monitor Your Web Site for Downtime

For those in the Internet business the availability of their... Read More

The Problem With Web Hosting Today

When it comes to web hosting, the quality of the... Read More

How to Choose a Right Web Hosting Service?

Indeed, choosing a right web hosting service for your website... Read More

efficient cleaning crew Highland Park ..