dig command trace delegation path from root servers for a domain name

Fig.04: Tracing of the delegation path from the root name servers

Fig.04: Tracing of the delegation path from the root name servers

The +trace option is very useful as it can trace the delegation path from the root name servers for the name being looked up. Tracing is disabled by default. When tracing is enabled, dig makes iterative queries to resolve the name being looked up. It will follow referrals from the root servers, showing the answer from each server that was used to resolve the lookup. Use this option to debug and troubleshoot your dns server problems.

Syntax

dig +trace example.com
dig +short +trace example.com

Example: dig trace path for www.cyberciti.biz

$ dig www.cyberciti.biz +trace

; <<>> DiG 9.8.2rc1-RedHat-9.8.2-0.17.rc1.el6_4.6 <<>> www.cyberciti.biz +trace
;; global options: +cmd
.			2616	IN	NS	d.root-servers.net.
.			2616	IN	NS	l.root-servers.net.
.			2616	IN	NS	k.root-servers.net.
.			2616	IN	NS	f.root-servers.net.
.			2616	IN	NS	e.root-servers.net.
.			2616	IN	NS	a.root-servers.net.
.			2616	IN	NS	m.root-servers.net.
.			2616	IN	NS	c.root-servers.net.
.			2616	IN	NS	b.root-servers.net.
.			2616	IN	NS	i.root-servers.net.
.			2616	IN	NS	h.root-servers.net.
.			2616	IN	NS	g.root-servers.net.
.			2616	IN	NS	j.root-servers.net.
;; Received 228 bytes from 10.0.80.11#53(10.0.80.11) in 215 ms
 
biz.			172800	IN	NS	a.gtld.biz.
biz.			172800	IN	NS	b.gtld.biz.
biz.			172800	IN	NS	c.gtld.biz.
biz.			172800	IN	NS	e.gtld.biz.
biz.			172800	IN	NS	f.gtld.biz.
biz.			172800	IN	NS	k.gtld.biz.
;; Received 316 bytes from 199.7.83.42#53(199.7.83.42) in 68 ms
 
cyberciti.biz.		7200	IN	NS	NS-1075.AWSDNS-06.ORG.
cyberciti.biz.		7200	IN	NS	NS-866.AWSDNS-44.NET.
cyberciti.biz.		7200	IN	NS	NS-243.AWSDNS-30.COM.
cyberciti.biz.		7200	IN	NS	NS-1947.AWSDNS-51.CO.UK.
;; Received 175 bytes from 2001:503:e239::3:2#53(2001:503:e239::3:2) in 254 ms
 
www.cyberciti.biz.	604800	IN	A	75.126.153.206
cyberciti.biz.		172800	IN	NS	ns-1075.awsdns-06.org.
cyberciti.biz.		172800	IN	NS	ns-1947.awsdns-51.co.uk.
cyberciti.biz.		172800	IN	NS	ns-243.awsdns-30.com.
cyberciti.biz.		172800	IN	NS	ns-866.awsdns-44.net.
;; Received 191 bytes from 205.251.196.51#53(205.251.196.51) in 25 ms

Examples and usage: Linux and Unix dig Command Examples