Setup Unbound DNS cache & resolver on Debian Buster

sudo apt install unbound

sudo tee -a /etc/unbound/unbound.conf << EOF > /dev/null

interface: ::1
access-control: allow
access-control: ::1/128 allow

# enable remote-control (useful when utilising monitoring tools such as netdata)
    control-enable: yes
sudo systemctl restart unbound
sudo apt install resolvconf
sudo nano /etc/network/interfaces

change nameservers to for IPv4 & ::1 for IPv6

sudo resolvconf -u


sudo apt install dnsutils
nslookup # Server:

I was also using this unbound instance to provide a DNS resolver to VMs attached to a bridge interface. Unfortunately, the interface wouldn’t be up before unbound would try to start. This was resolved by adding a ExecStartPre directive to Unbound’s Systemd service file:

sudo systemctl edit unbound

Add the following lines to the ### Anything between here and the comment below will become the new contents of the file section.

ExecStartPre=/usr/lib/systemd/systemd-networkd-wait-online --interface=br0 --timeout=120