| Crates.io | dns-query-monitor |
| lib.rs | dns-query-monitor |
| version | 0.1.0 |
| created_at | 2025-12-19 18:33:27.681236+00 |
| updated_at | 2025-12-19 18:33:27.681236+00 |
| description | Real-time DNS query monitoring tool with Terminal User Interface |
| homepage | |
| repository | https://github.com/yinheli/dns-query-monitor |
| max_upload_size | |
| id | 1995257 |
| size | 107,855 |
Real-time DNS query monitoring tool with Terminal User Interface (TUI).
# Ubuntu/Debian
sudo apt-get install libpcap-dev
# Fedora/RHEL
sudo dnf install libpcap-devel
# Arch Linux
sudo pacman -S libpcap
# Pull from Docker Hub
docker pull yinheli/dns-query-monitor
# Run with host network mode
# --net=host: Share host's network namespace to access all network interfaces
# --cap-add=NET_ADMIN: Grant network administration capabilities for packet capture
docker run --rm -it --cap-add=NET_ADMIN --net=host \
yinheli/dns-query-monitor
# From crates.io
cargo install dns-query-monitor
# From git repository
cargo install --git https://github.com/yinheli/dns-query-monitor
# Or clone and install locally
git clone https://github.com/yinheli/dns-query-monitor
cd dns-query-monitor
cargo install --path .
# Clone repository
git clone https://github.com/yinheli/dns-query-monitor
cd dns-query-monitor
# Build
cargo build --release
# Binary location
./target/release/dns-query-monitor
# Auto-select interface (default)
docker run --rm -it --cap-add=NET_ADMIN --net=host \
yinheli/dns-query-monitor
# List available network interfaces
docker run --rm -it --cap-add=NET_ADMIN --net=host \
yinheli/dns-query-monitor --list-interfaces
# Monitor specific interface
docker run --rm -it --cap-add=NET_ADMIN --net=host \
yinheli/dns-query-monitor -i eth0
# Filter by domain
docker run --rm -it --cap-add=NET_ADMIN --net=host \
yinheli/dns-query-monitor -f google
# List available network interfaces
sudo dns-query-monitor --list-interfaces
# Auto-select interface (default)
sudo dns-query-monitor
# Monitor specific interface
sudo dns-query-monitor -i eth0
# Filter by domain
sudo dns-query-monitor -f google
-i, --interface <INTERFACE> Network interface (auto-detect if not specified)
-f, --filter <FILTER> Filter domain names
-l, --log-level <LEVEL> Log level [default: info]
--list-interfaces List available network interfaces
-h, --help Show help
| Key | Action |
|---|---|
q / Ctrl+C |
Quit program |
Esc |
Exit filter mode |
/ |
Enter filter mode |
s |
Toggle sort (Time → Count → Domain) |
↑ ↓ / j k |
Navigate |
PgUp / PgDn |
Page up/down |
Home / End |
Jump to top/bottom |
Tip: You can select text with your mouse and copy with
Ctrl+Shift+C(Linux) orCmd+C(macOS) directly from the terminal.
┌─ DNS Query Monitor | Domains: 42 | Queries: 156 ──────────────────────┐
│ │
└───────────────────────────────────────────────────────────────────────┘
┌─ DNS Queries [Sort: Time ↓] ──────────────────────────────────────────┐
│ Domain │ IP Address │ Last Query │ Count │
│ example.com │ 1.1.1.1 │ 2024-06-01 12:00:00 │ 5 │
│ github.com │ 8.8.8.8 │ 2024-06-01 11:59:45 │ 12 │
└───────────────────────────────────────────────────────────────────────┘
Permission denied: Run with sudo
No queries captured:
ip link showdig example.com-l debugip1, ip2, ... (+3))MIT