This is an installation using version 4.9.
1. Add the PowerDNS repo.
echo "deb [signed-by=/etc/apt/keyrings/rec-49-pub.asc arch=amd64] http://repo.powerdns.com/debian bullseye-rec-49 main" > /etc/apt/sources.list.d/pdns.list
2. Modify apt preferences
cat << EOF > /etc/apt/preferences.d/pdns
Package: rec*
Pin: origin repo.powerdns.com
Pin-Priority: 600
EOF
3. Add the PowerDNS apt key.
install -d /etc/apt/keyrings
curl https://repo.powerdns.com/FD380FBB-pub.asc | tee /etc/apt/keyrings/rec-49-pub.asc
4. Update and install.
apt update
apt install pdns-recursor
/etc/powerdns/recursor.conf
allow-from=
config-dir=/etc/powerdns
include-dir=/etc/powerdns/recursor.d
local-address=0.0.0.0
local-port=53
log-common-errors=yes
logging-facility=0
loglevel=4
quiet=yes
setgid=pdns
setuid=pdns
webserver=yes
webserver-address=0.0.0.0
webserver-allow-from=0.0.0.0/0