a DNS client

introduction

A DNS (Domain Name System) client deals with names and addresses in the Internet.

All Internet services use DNS. DNS provides a way of giving memorable names to IP addresses. A DNS contains a DNS server, DNS client, data stores and protocols. The protocols describe how applications can talk to each other about domains.

nslookup, dig and host and DNS clients.

what it is

A DNS client that looks up IP addresses and host names is called a resolver. There is another type of client called a

a DNS client contacts a DNS server
 

DNS client

image image

DNS server
in the LIC

 
Internet

dynamic DNS client. A dynamic DNS client program updates a DNS server with your IP address. This is useful if you have an IP address that changes regularly, which is the case for nearly every person renting an Internet connection from an ISP.

The client program nslookup (Name Server LOOKUP) is a resolver that is available just about everywhere. nslookup is an interactive resolver that can only talk to a DNS server. nslookup has been around for decades and is available on most operating systems. dig and host are newer DNS clients found on Linux hosts.
C:\>nslookup www.google.com
Server:  dns.domain.com
Address:  10.100.101.102

Non-authoritative answer:
Name:    www.google.akadns.net
Addresses:  216.239.59.99, 216.239.59.104, 216.239.59.147
Aliases:  www.google.com

C:\>

A DNS client keeps copies of answers it receives from the DNS server. This is called the DNS cache. The first time a DNS client is told to look up an address, it asks the server. The second time it gets the answer from its cache. The first answer is called authoritative and the second answer non-authoritative. The DNS client removes an answer from its cache after a few hours just in case details have changed on the server.

A DNS client is not limited to asking a DNS server. If it is running on a UNIX host it can look in database files such as /etc/hosts and it can ask other services such as NIS (Network Information Service). The list of files, services and general things to query is kept in a database file called /etc/nsswitch.conf.

A DNS client must know where the DNS server is. UNIX hosts have the file /etc/resolv.conf that contains the local domain and the addresses of DNS servers for that domain.

A programmer who creates an application can include a DNS client built into it. The programmer does not need to write lots of DNS client code to use DNS. There is a library of functions called NSL (Name Server Library) which provides the tricky bits ready made.

what it isn't

Usually used by people. Most DNS lookups are done by programs like web browsers.

A dynamic DNS client. No dynamic DNS clients are used in the LIC.

where it is

Everywhere. Just about every program that has anything to do with the Internet has a DNS client built into it.

history

In 1983 Paul Mockapetris created the DNS client, server and everything else.