Nslookup Command Examples To Check DNS Records

Nslookup Command Examples To Check DNS Records

 Find out the domain IP address / A record

[root@web ~]# nslookup arstech.net
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
Name:   arstech.net
Address: 213.136.71.197

 

Find out the domain MX record

[root@web ~]# nslookup -query=mx arstech.net
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
arstech.net     mail exchanger = 10 mail.arstech.net.

Authoritative answers can be found from:
mail.arstech.net        internet address = 213.136.71.197

 

Find out the domain NS record

[root@web ~]# nslookup -type=ns google.com
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
google.com      nameserver = ns1.google.com.
google.com      nameserver = ns3.google.com.
google.com      nameserver = ns4.google.com.
google.com      nameserver = ns2.google.com.

Authoritative answers can be found from:
ns1.google.com  internet address = 216.239.32.10
ns3.google.com  internet address = 216.239.36.10
ns4.google.com  internet address = 216.239.38.10
ns2.google.com  internet address = 216.239.34.10

 

Find out the domain TXT (SPF) record

[root@web ~]# nslookup -type=txt google.com
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
google.com      text = "v=spf1 include:_spf.google.com ~all"

 

Find out the domain CNAME record

[root@web ~]# nslookup -type=cname google.com
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
*** Can't find google.com: No answer

Authoritative answers can be found from:
google.com
        origin = ns1.google.com
        mail addr = dns-admin.google.com
        serial = 101716444
        refresh = 7200
        retry = 1800
        expire = 1209600
        minimum = 300

 

Find out the domain SOA record

[root@web ~]# nslookup -type=soa google.com
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
google.com
        origin = ns1.google.com
        mail addr = dns-admin.google.com
        serial = 4294967295
        refresh = 7200
        retry = 1800
        expire = 1209600
        minimum = 300

Authoritative answers can be found from:
google.com      nameserver = ns2.google.com.
google.com      nameserver = ns1.google.com.
google.com      nameserver = ns4.google.com.
google.com      nameserver = ns3.google.com.
ns2.google.com  internet address = 216.239.34.10
ns1.google.com  internet address = 216.239.32.10
ns4.google.com  internet address = 216.239.38.10
ns3.google.com  internet address = 216.239.36.10

 

Find out the domain reverse DNS (PTR) record

[root@web ~]# nslookup 173.194.116.128
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
128.116.194.173.in-addr.arpa    name = fra02s28-in-f0.1e100.net.

 

Find out ALL domain records

[root@web ~]# nslookup -type=any yahoo.com
Server:         213.136.95.11
Address:        213.136.95.11#53

Non-authoritative answer:
yahoo.com
        origin = ns1.yahoo.com
        mail addr = hostmaster.yahoo-inc.com
        serial = 2015082714
        refresh = 3600
        retry = 300
        expire = 1814400
        minimum = 600
Name:   yahoo.com
Address: 98.138.253.109
Name:   yahoo.com
Address: 98.139.183.24
Name:   yahoo.com
Address: 206.190.36.45
yahoo.com       mail exchanger = 1 mta5.am0.yahoodns.net.
yahoo.com       mail exchanger = 1 mta7.am0.yahoodns.net.
yahoo.com       mail exchanger = 1 mta6.am0.yahoodns.net.
yahoo.com       nameserver = ns4.yahoo.com.
yahoo.com       nameserver = ns1.yahoo.com.
yahoo.com       nameserver = ns3.yahoo.com.
yahoo.com       nameserver = ns6.yahoo.com.
yahoo.com       nameserver = ns5.yahoo.com.
yahoo.com       nameserver = ns2.yahoo.com.
yahoo.com       text = "v=spf1 redirect=_spf.mail.yahoo.com"
yahoo.com       has AAAA address 2001:4998:58:c02::a9
yahoo.com       has AAAA address 2001:4998:44:204::a7
yahoo.com       has AAAA address 2001:4998:c:a06::2:4008

Authoritative answers can be found from:
ns1.yahoo.com   internet address = 68.180.131.16
ns1.yahoo.com   has AAAA address 2001:4998:130::1001
ns2.yahoo.com   internet address = 68.142.255.16

Find out particular nameserver IP address / record

[root@web ~]# nslookup arstech.net ns1.contabo.net       
Server:         ns1.contabo.net
Address:        2a02:c200:0:10::882:1#53

Name:   arstech.net
Address: 213.136.71.197

 

 Find out detailed information using DEBUG mode

[root@web ~]# nslookup -debug arstech.net         
Server:         213.136.95.11
Address:        213.136.95.11#53

------------
    QUESTIONS:
        arstech.net, type = A, class = IN
    ANSWERS:
    ->  arstech.net
        internet address = 213.136.71.197
        ttl = 47111
    AUTHORITY RECORDS:
    ADDITIONAL RECORDS:
------------
Non-authoritative answer:
Name:   arstech.net
Address: 213.136.71.197

 

 

 

arstech

Leave a Reply