Nslookup

The conversion between domain names and IP addresses is done by a system of domain name servers. These servers are usually called by client programs, but they can also be queried manually, using the Unix or Windows XP command-line command nslookup.

The following examples show nslookup finding the IP address for sws.csudh.edu and then doing a reverse lookup on 155.135.1.163 which returns sws.csudh.edu.

C:\>nslookup sws.csudh.edu
Server:  vnsc-bak-dsl.genuity.net
Address:  4.2.2.5

Non-authoritative answer:
Name:    sws.csudh.edu
Address:  155.135.1.163
C:\>nslookup 155.135.1.163
Server:  vnsc-bak-dsl.genuity.net
Address:  4.2.2.5

Non-authoritative answer:
Name:    sws.csudh.edu
Address:  155.135.1.163

The DNS server that found the answer was running on vnsc-bak-dsl.genuity.net which is on the backbone network my ISP uses. I ran the above demonstration at home.

I then ran the same demonstration on campus:

C:\>nslookup sws.csudh.edu
Server:  ns.csudh.edu
Address:  10.17.0.40

Name:    sws.csudh.edu
Address:  10.26.0.157
C:\>nslookup 10.26.0.157
Server:  ns.csudh.edu
Address:  10.17.0.40

Name:    sws.csudh.edu
Address:  10.26.0.157

Since I was inside the campus firewall, I saw the internal, non-routable address of sws.csudh.edu. The result was returned by a DNS server running on ns.csudh.edu inside our firewall.

The external, routable IP address 155.135.1.163 corresponds to the internal, non-routable IP address 10.26.0.157 . Network address translation, NAT, is conversion between corresponding internal and external IP addresses.

Instead of the nslookup command, you can a Web service like DNSStuff.com to make domain name and other queries. (DNSStuff calls nslookup for you).


Disclaimer: The views and opinions expressed on unofficial pages of California State University, Dominguez Hills faculty, staff or students are strictly those of the page authors. The content of these pages has not been reviewed or approved by California State University, Dominguez Hills.