Unbound keep getting SERVFAIL

Hi,

I tried everything, nothing really help. Also I'm newbie.

dig pi-hole.net @ 127.0.0.1 -p 5335
<<>> DiG 9.16.27-Raspbian <<>> pi-hole.net @ 127.0.0.1 -p 5335
global options: +cmd
Got answer:
->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 48133
flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 1

OPT PSEUDOSECTION:
EDNS: version: 0, flags:; udp: 1472
 QUESTION SECTION:
pi-hole.net.                   IN      A

 Query time: 0 msec
SERVER: 127.0.0.1#5335(127.0.0.1)
WHEN: Sat Apr 09 23:41:58 IDT 2022
MSG SIZE  rcvd: 40

unbound-checkconf:
no errors in /etc/unbound/unbound.conf

/etc/unbound/unbound.conf:include-toplevel: "/etc/unbound/unbound.conf.d/*.conf"
/etc/unbound/unbound.conf.d/resolvconf_resolvers.conf:forward-zone:
/etc/unbound/unbound.conf.d/resolvconf_resolvers.conf:  name: "."
/etc/unbound/unbound.conf.d/resolvconf_resolvers.conf:  forward-addr: 2a00:a040:0:200::1
/etc/unbound/unbound.conf.d/resolvconf_resolvers.conf:  forward-addr: 2001:4860:4860::8888
/etc/unbound/unbound.conf.d/root-auto-trust-anchor-file.conf:server:
/etc/unbound/unbound.conf.d/root-auto-trust-anchor-file.conf:    auto-trust-anchor-file: "/var/lib/unbound/root.key"
/etc/unbound/unbound.conf.d/pi-hole.conf:server:
/etc/unbound/unbound.conf.d/pi-hole.conf:    verbosity: 0
/etc/unbound/unbound.conf.d/pi-hole.conf:    interface: 127.0.0.1
/etc/unbound/unbound.conf.d/pi-hole.conf:    port: 5335
/etc/unbound/unbound.conf.d/pi-hole.conf:    do-ip4: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    do-udp: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    do-tcp: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    do-ip6: no
/etc/unbound/unbound.conf.d/pi-hole.conf:    prefer-ip6: no
/etc/unbound/unbound.conf.d/pi-hole.conf:    harden-glue: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    harden-dnssec-stripped: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    use-caps-for-id: no
/etc/unbound/unbound.conf.d/pi-hole.conf:    edns-buffer-size: 1472
/etc/unbound/unbound.conf.d/pi-hole.conf:    prefetch: yes
/etc/unbound/unbound.conf.d/pi-hole.conf:    num-threads: 1
/etc/unbound/unbound.conf.d/pi-hole.conf:    so-rcvbuf: 1m
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: 192.168.0.0/16
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: 169.254.0.0/16
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: 172.16.0.0/12
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: 10.0.0.0/8
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: fd00::/8
/etc/unbound/unbound.conf.d/pi-hole.conf:    private-address: fe80::/10

unbound.service - Unbound DNS server

 Loaded: loaded (/lib/systemd/system/unbound.service; enabled; vendor preset: enabled)
     Active: active (running) since Sat 2022-04-09 23:15:13 IDT; 21min ago
       Docs: man:unbound(8)
    Process: 26687 ExecStartPre=/usr/lib/unbound/package-helper chroot_setup (code=exited, status=0/SUCCESS)
    Process: 26690 ExecStartPre=/usr/lib/unbound/package-helper root_trust_anchor_update (code=exited, status=0/SUCCESS)
   Main PID: 26693 (unbound)
      Tasks: 1 (limit: 3720)
        CPU: 147ms
     CGroup: /system.slice/unbound.service
             └─26693 /usr/sbin/unbound -d -p

Apr 09 23:15:13 raspberrypi systemd[1]: Starting Unbound DNS server...
Apr 09 23:15:13 raspberrypi unbound[26693]: [26693:0] info: start of service (unbound 1.13.1).
Apr 09 23:15:13 raspberrypi systemd[1]: Started Unbound DNS server.

Debug Token:

[(https://tricorder.pi-hole.net/Anpub8Ld/)]

Hope I did right and thanks.

1 Like
  1. Edit file /etc/resolvconf.conf and comment out the last line which should read:

unbound_conf=/etc/unbound/unbound.conf.d/resolvconf_resolvers.conf

  1. Delete the unwanted unbound configuration file:

sudo rm /etc/unbound/unbound.conf.d/resolvconf_resolvers.conf

  1. Restart unbound:

sudo service unbound restart

2 Likes

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.