brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: tcpdump -ni any port 53 shows linux DNS traffic without Wireshark

Linux
~/tips/tip-linux-tcpdump-port-53-dns

sudo tcpdump -ni any port 53 -c 20

Captures a few DNS packets from the command line and prints them.

For a quick look at what leaves a machine, tcpdump on the command line is enough for me.

sudo tcpdump -ni any port 53 -c 20

-n skips name lookups, which would create more DNS traffic while you watch DNS. -i any listens on all interfaces, port 53 is a capture filter, and -c 20 stops after twenty packets. Capture filters run in the kernel, so they cost less than filtering afterwards. It needs root. DNS over TLS or HTTPS will not show readable queries on port 53.

Further reading: tcpdump manual page

More Linux tips a2query -m rewrite renice -n 10 -p 4242 cat config.yml | xsel -ib xvfb-run -a your-program --some-flag dpkg --get-selections > packages.txt All Linux tips (261) All topics

Link