Windows

Explore the Nslookup.exe tool in Windows 2000 Server

Nslookup.exe is a powerful troubleshooting tool for DNS included with Windows 2000 Server, allowing you to perform DNS queries, obtain detailed information from the command prompt, and debug DNS problems. Learn a few basic commands and run your servers more smoothly.

The primary troubleshooting tool for DNS included with Windows 2000 Server and other DNS implementations is Nslookup.exe. This tool can be used to perform DNS queries, obtain detailed information from the command prompt, and debug DNS problems.

You can use Nslookup in interactive and non-interactive modes. Non-interactive mode is useful for looking up a single piece of data, such as one DNS record. To use Nslookup in non-interactive mode, type nslookup <name> <server>, where <name> is the name of the record you're looking for and <server> is the name of the DNS server you want to query.

Interactive mode is much more powerful. To enter the interactive mode, you have to type nslookup at the command prompt. You end up in the Nslookup prompt, where you can use special commands such as set or ls, which can be used to list all records or records of a given type in a specified domain. To get a list of all available commands, type ?.

The most simple use is a query for an A record. To get an IP address of a host name, just type its name in the Nslookup prompt. Nslookup will then query the DNS server for this host name and return the result. If it doesn't return the expected result, you can debug to see the exact request and answer packets. You turn the full debugging on by typing set d2, and you turn it off by typing nod2 in the Nslookup prompt. You can also specify the type of records you're looking for: A, CNAME, MX, NS, etc.

Miss a column?

Check out the Windows 2000 Server archive, and catch up on the all the Windows 2000 Server columns.

Want more Windows 2000 Server tips and tricks? Automatically sign up for our free Windows 2000 Server newsletter, delivered each Tuesday!

3 comments
shanthar
shanthar

trouble shooting tool for DNS are windows 2000 server and NS lookup exe.the tool performs DNS queries and debugs DNS problems.Ns look up.exeis used in interactive and non-interactive modes. The mode is use dfor looking up a single data. It is Dns record.to use Ns lookup in non interactive modetype ns lookup _name of the record_ the name of the DNS server {that is to be questioned} Interactive mode is more powerful. To enter the mode typeNs lookup at the command prompt{ns lookup prompt} you can use special commandsas setor isthat is used to list all recordsor records of a giventype ina specified domain{ for the list of all commands type].The simple use is a queryfor a record. To get an IP addressof a host namein the Nslookup prompt. If the result is not shown, you can debug to see the request and answer packets. The full debugging is onby typing set d2 and turn it off by typing nod2in the Ns lookup prompt.you can also specify the records you are A, Cname ,Mx, Ns etc.

wdewey@cityofsalem.net
wdewey@cityofsalem.net

I personally use dig. I find it much more flexible and easier to use. It doesn't come standard on windows, but should be fairly easy to find. Bill

steve.moss
steve.moss

I use both, depends on my mood. Hadn't tried ls or debug options with nslookup but will now.

Editor's Picks