You can think of Julia Evans’ new
dnspeep tool as similar to
tcpdump but specifically for watching your machine’s DNS queries.
One thing I like about this tool is that it gives me a sense for what programs on my computer are using the Internet! For example, I found out that something on my computer is making requests to ping.manjaro.org from time to time for some reason, probably to check I’m connected to the internet.
A friend of mine actually discovered using this tool that he had some corporate monitoring software installed on his computer from an old job that he’d forgotten to uninstall, so you might even find something you want to remove.
It also probably comes in handy when debugging those pesky “could it be DNS?” issues, but this might be a limitation on that front:
One thing this program doesn’t do is tell you which process made the DNS query, there’s a tool called dnssnoop I found that does that. It uses eBPF and it looks cool but I haven’t tried it.