Ich habe pi-hole sowohl als Werbeblocker, als auch als lokalen DNS in Gebrauch.
die Interfaces, auf denen er "horcht", sind 127.0.0.1 und 192.168.146.167; jeweils auf Port 53.
Beobachtetes und erwartetes Verhalten
129.168.146.167 ist auf den anderen Rechnern im Netz als DNS eingetragen. Alle Adressen werden aufgelöst.
Leider werden auch die Einträge der Blockliste aufgelöst, der Zähler "Queries Blocked" bleibt auf 0.
Aus der shell auf dem DNS habe ich folgendes Verhalten:
$ nslookup flurry.com
Server: 192.168.146.167
Address: 192.168.146.167#53
Non-authoritative answer:
Name: flurry.com
Address: 34.213.101.254
Name: flurry.com
Address: 34.225.127.72
Name: flurry.com
Address: 54.161.105.65
Name: flurry.com
Address: 18.136.37.69
Name: flurry.com
Address: 13.49.212.207
Name: flurry.com
Address: 13.251.69.97
Name: flurry.com
Address: 44.228.206.170
Name: flurry.com
Address: 13.50.184.192
Verwende ich 127.0.0.1 als DNS, ist alles in Ordnung:
$ nslookup flurry.com 127.0.0.1
Server: 127.0.0.1
Address: 127.0.0.1#53
Name: flurry.com
Address: 0.0.0.0
Die Gegenprobe liefert sowohl auf 127.0.0.1, als auch auf 192.168.146.167 gültige Antworten:
$ nslookup heise.de 127.0.0.1
Server: 127.0.0.1
Address: 127.0.0.1#53
Non-authoritative answer:
Name: heise.de
Address: 193.99.144.80
Name: heise.de
Address: 2a02:2e0:3fe:1001:302::
$ nslookup heise.de
Server: 192.168.146.167
Address: 192.168.146.167#53
Non-authoritative answer:
Name: heise.de
Address: 193.99.144.80
Name: heise.de
Address: 2a02:2e0:3fe:1001:302::
Die Einträge in /etc/dnsmasq.d/10-local.conf:
listen-address=127.0.0.1
listen-address=192.168.146.167
# Port
port=53
bind-interfaces
/etc/resolv.conf sieht so aus:
nameserver 192.168.146.167
netstat -ltnp |grep ":53 " liefert:
tcp 0 0 192.168.146.167:53 0.0.0.0:* LISTEN 318037/pihole-FTL
tcp 0 0 127.0.0.1:53 0.0.0.0:* LISTEN 318037/pihole-FTL
Die relevanten log entries in pihole.log:
Jan 1 22:56:22 dnsmasq[318037]: query[A] flurry.com from 127.0.0.1
Jan 1 22:56:22 dnsmasq[318037]: gravity blocked flurry.com is 0.0.0.0
Jan 1 22:56:22 dnsmasq[318037]: query[AAAA] flurry.com from 127.0.0.1
Jan 1 22:56:22 dnsmasq[318037]: forwarded flurry.com to 127.0.0.1#5335
Jan 1 22:56:22 dnsmasq[318037]: dnssec-query[DS] flurry.com to 127.0.0.1#5335
Jan 1 22:56:22 dnsmasq[318037]: reply flurry.com is no DS
Jan 1 22:56:22 dnsmasq[318037]: validation result is INSECURE
Jan 1 22:56:22 dnsmasq[318037]: reply flurry.com is NODATA-IPv6
Jan 1 22:38:33 dnsmasq[317834]: query[A] flurry.com from 192.168.146.167
Jan 1 22:38:33 dnsmasq[317834]: forwarded flurry.com to 127.0.0.1#5335
Jan 1 22:38:33 dnsmasq[317834]: validation result is INSECURE
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 34.213.101.254
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 34.225.127.72
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 54.161.105.65
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 18.136.37.69
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 13.49.212.207
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 13.251.69.97
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 44.228.206.170
Jan 1 22:38:33 dnsmasq[317834]: reply flurry.com is 13.50.184.192
Letztlich sieht es so aus, als würde pi-hole die Anfrage an 192.168.146.167 unmittelbar an den Upstream-Server (unbound auf 127.0.0.1#5335) weiterleiten, der dann natürlich eine Antwort liefert.
Wo liegt das Problem? Welchen Fehler habe ich gemacht?
Danke schon mal für eure Hilfe.