nslookup

From Wikipedia, the free encyclopedia

Jump to: navigation, search

nslookup is a computer program used in Windows and Unix to query Domain Name System (DNS) servers to find DNS details, including IP addresses of a particular computer, MX records for a domain and the NS servers of a domain. The name nslookup means "name server lookup". The most common version of the program is included as part of the BIND package. More modern alternatives to nslookup are the "host" and "dig" programs which also ship with BIND.

nslookup has the subcommands:

  • server NAME (where NAME is the name or IP address of a DNS server to query). It is not always possible to query a specific DNS server as often DNS queries are blocked to prevent denial of service attacks.
  • set type=NAME (where NAME is the type of record to look at). For example, set type mx will give the mail records.

[edit] Example usage

Command line:

unix% nslookup example.com

Server:        192.168.1.1
Address:    192.168.1.1#53

Non-authoritative answer:
Name:    example.com
Address: 208.77.188.166

Using subcommands:

nslookup

> server dns.com
Default Server:  dns.com
Address:  169.254.82.215

> set type=mx
> microsoft.com
Server:  dns.com
Address:  64.40.103.249


microsoft.com   MX preference = 0, mail exchanger = nullmx.domainmanager.com
> exit

[edit] Interpretation of the standard nslookup result

The first two lines are information about the name server delivering the response. The next two lines show the name and IP address of the machine being looked up.

[edit] External links

Personal tools