15

dig +trace google.com

; <<>> DiG 9.10.6 <<>> +trace google.com
;; global options: +cmd
;; Received 12 bytes from 100.98.0.0#53(100.98.0.0) in 388 ms

dig google.com +trace

; <<>> DiG 9.10.6 <<>> google.com +trace
;; global options: +cmd
;; Received 12 bytes from 100.98.0.0#53(100.98.0.0) in 383 ms

I'm on MacOSX 10.14.1 Mojave...

uname -a

Darwin *****.local 18.2.0 Darwin Kernel Version 18.2.0: Fri Oct  5 19:41:49 PDT 2018; root:xnu-4903.221.2~2/RELEASE_X86_64 x86_64

Both the man page for dig, and several threads online, indicate I'm issuing the correct command, but it doesn't show any trace..it just says it received 12 bytes and the ip address that was resolved.

Calicoder
  • 1,322
  • 1
  • 19
  • 37

2 Answers2

24

don't have a Mac here, but this probably has something to do with your DNS server. have you tried another server, like 8.8.8.8?

when use 127.0.0.53, as name server:

; <<>> DiG 9.11.3-1ubuntu1.3-Ubuntu <<>> +trace stackoverflow.com
;; global options: +cmd
;; Received 28 bytes from 127.0.0.53#53(127.0.0.53) in 0 ms

when use Google's name server:

dig @8.8.8.8 +trace stackoverflow.com

; <<>> DiG 9.11.3-1ubuntu1.3-Ubuntu <<>> @8.8.8.8 +trace stackoverflow.com
; (1 server found)
;; global options: +cmd
.           303502  IN  NS  j.root-servers.net.
.           303502  IN  NS  d.root-servers.net.
.           303502  IN  NS  g.root-servers.net.
.           303502  IN  NS  a.root-servers.net.
.           303502  IN  NS  b.root-servers.net.
.           303502  IN  NS  f.root-servers.net.
.           303502  IN  NS  i.root-servers.net.
.           303502  IN  NS  m.root-servers.net.
.           303502  IN  NS  k.root-servers.net.
.           303502  IN  NS  e.root-servers.net.
.           303502  IN  NS  h.root-servers.net.
.           303502  IN  NS  c.root-servers.net.
.           303502  IN  NS  l.root-servers.net.
;; Received 779 bytes from 8.8.8.8#53(8.8.8.8) in 13 ms

com.            172800  IN  NS  a.gtld-servers.net.
com.            172800  IN  NS  b.gtld-servers.net.
com.            172800  IN  NS  c.gtld-servers.net.
com.            172800  IN  NS  d.gtld-servers.net.
com.            172800  IN  NS  e.gtld-servers.net.
com.            172800  IN  NS  f.gtld-servers.net.
com.            172800  IN  NS  g.gtld-servers.net.
com.            172800  IN  NS  h.gtld-servers.net.
com.            172800  IN  NS  i.gtld-servers.net.
com.            172800  IN  NS  j.gtld-servers.net.
com.            172800  IN  NS  k.gtld-servers.net.
com.            172800  IN  NS  l.gtld-servers.net.
com.            172800  IN  NS  m.gtld-servers.net.
com.            86400   IN  DS  30909 8 2 E2D3C916F6DEEAC73294E8268FB5885044A833FC5459588F4A9184CF C41A5766
com.            86400   IN  RRSIG   DS 8 1 86400 20190327050000 20190314040000 16749 . VxquNuaeJ1aPlma/m40LpD1IelriWx9IPUhLA8fCqvZNLjfsyCofrj++ FjM9w2PRu/vneFdQnYpqI5A6xRf9NqfUVh8AIRoSU/3oGZLU3ce8VOq/ YwIyL/eAGTIMOrcrd51s2ZReOoLDjf4hp/Z6VVOUZpnOxiwQOjGM0Dt+ UIhNlOni0msLDFHW0vYvDxOM3a15S4itfmWrzS2wOU5oqA1scclYRILB tEsHhGVvrVcrv2YLlOshWyrERm10/fHoiHzpniQo/Zfjke4HEjSLxpH1 rWnXm8isVhjKp8W3R4ivLxvTRKeE/7jUP410znIPLg1Ss2m+hAsyl5sR uvzHMQ==
;; Received 1177 bytes from 198.97.190.53#53(h.root-servers.net) in 337 ms

stackoverflow.com.  172800  IN  NS  ns-358.awsdns-44.com.
stackoverflow.com.  172800  IN  NS  ns-1033.awsdns-01.org.
stackoverflow.com.  172800  IN  NS  ns-cloud-e1.googledomains.com.
stackoverflow.com.  172800  IN  NS  ns-cloud-e2.googledomains.com.
CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN NSEC3 1 1 0 - CK0Q1GIN43N1ARRC9OSM6QPQR81H5M9A  NS SOA RRSIG DNSKEY NSEC3PARAM
CK0POJMG874LJREF7EFN8430QVIT8BSM.com. 86400 IN RRSIG NSEC3 8 2 86400 20190320044718 20190313033718 16883 com. YTcSUlhFZgK8Wgeu+V93aK5p2ZW3/AYky/JnYF2LAch69qEoGKl0GwHP Qom4epMAf7OAzacjStETSpV1+vAXr0WbdjQ90rnFhkx+sWAYcl8IyKSd nipHSI2CFZJUsIzBl5vyVebRT2erkpQZvseO2jkGZjWxhmQh0APBI+Ju KSI=
QJLANLBLFPUKKIO73G776E7389OP43C0.com. 86400 IN NSEC3 1 1 0 - QJLBMGGUF1TGTFH7U479EFSNO84B6UPD  NS DS RRSIG
QJLANLBLFPUKKIO73G776E7389OP43C0.com. 86400 IN RRSIG NSEC3 8 2 86400 20190319051405 20190312040405 16883 com. jEIe8uoPLyZ90nMFJyX9MeheKiww+qbCV06AqonQaoKA2pwvbhVLd5H9 SEdGIWJvBn2RIJHSNJ3fbrj2GUYXTPmUAL7TglhxdSzswhIkoB1VOma2 Bd8/47MaCPCzPZ5SX2LRqo0njQX4I1VpvtiH/f8xbbMJUj4odyBWMK9D W3U=
;; Received 767 bytes from 192.55.83.30#53(m.gtld-servers.net) in 454 ms

stackoverflow.com.  300 IN  A   151.101.1.69
stackoverflow.com.  300 IN  A   151.101.65.69
stackoverflow.com.  300 IN  A   151.101.129.69
stackoverflow.com.  300 IN  A   151.101.193.69
;; Received 110 bytes from 216.239.34.110#53(ns-cloud-e2.googledomains.com) in 119 ms

Alan Cheng
  • 425
  • 3
  • 7
-1

If nothing helps, the following tips helped me:

  1. For some reason dig +trace some.domain.com doesn't always show the trace at the first attempt, but after a few attempts it works! Just enter the same command again and again.
  2. Rebooting may help! After that try the suggestion #1.
Alexander Fadeev
  • 2,110
  • 14
  • 16