unbound-control(8)
Control and monitor the Unbound DNS resolver daemon remotely.
Synopsis
unbound-control [-c config] [-s server] command [arg...]Description
unbound-control is a utility to remotely manage and query a running Unbound DNS resolver. It communicates with unbound(8) via a control socket using TLS, allowing administrators to reload configuration, flush caches, view statistics, and manage the daemon without restarting it.
The control socket location and authentication credentials are configured in unbound.conf(5). By default, unbound-control uses the control certificate and key files to authenticate with the daemon.
Common options
| Flag | What it does |
|---|---|
-c config | Read configuration from the specified file (default: /etc/unbound/unbound.conf) |
-s server | Connect to the specified server address:port (e.g., 127.0.0.1:8953) instead of the one in config |
-q | Quiet mode; suppress informational messages |
-h | Display help information and exit |
Examples
Check if unbound is running and display daemon status information
unbound-control statusReload the unbound configuration file without restarting the daemon
unbound-control reloadFlush the DNS cache for the example.com zone
unbound-control flush_zone example.comRemove a specific hostname and its associated data from the cache
unbound-control flush_name www.example.comDisplay resolver statistics including queries, cache hits, and response times
unbound-control statsShow statistics without resetting counters to zero
unbound-control stats_noresetOutput the entire contents of the DNS cache for debugging
unbound-control dump_cacheQuery the status of an unbound daemon running on a remote machine
unbound-control -s 192.168.1.10:8953 status