Nslookup is a nice tool to check all records registered with each domain name and with their services. For example, if we need to know the IP address of SMTP server of a particular domain or a list of all name servers responsible for resolving a particular domain, then we can use nslookup command.
When you run the nslookup command, by-default, it assumes that you are querying an internal domain on your network. To tell nslookup to use external DNS for retrieving records information, we have to specify the DNS server address with nslookup command.