Temporary failure in name resolution - only on localhost

I am running pi-hole in a VM on Ubuntu 18.04 - since "ages", no problems.

Since the last update, I am getting "Temporary failure in name resolution" errors on the pi-hole VM. All other clients get fed with DNS replies by pi-hole, but on the machine itself, it is not working. I can get it to work by replacing "nameserver 127.0.0.53" in /etc/resolv.conf with some other nameserver.

Is this a common problem with the update?

pihole-FTL.log:

[2020-07-20 20:18:18.420 2294M] Using log file /var/log/pihole-FTL.log
[2020-07-20 20:18:18.420 2294M] ########## FTL started! ##########
[2020-07-20 20:18:18.420 2294M] FTL branch: master
[2020-07-20 20:18:18.420 2294M] FTL version: v5.1
[2020-07-20 20:18:18.420 2294M] FTL commit: b522646
[2020-07-20 20:18:18.420 2294M] FTL date: 2020-07-15 22:26:33 +0100
[2020-07-20 20:18:18.420 2294M] FTL user: pihole
[2020-07-20 20:18:18.420 2294M] Compiled for x86_32 (compiled on CI) using gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516
[2020-07-20 20:18:18.420 2294M] Starting config file parsing (/etc/pihole/pihole-FTL.conf)
[2020-07-20 20:18:18.420 2294M]    SOCKET_LISTENING: only local
[2020-07-20 20:18:18.420 2294M]    AAAA_QUERY_ANALYSIS: Show AAAA queries
[2020-07-20 20:18:18.421 2294M]    MAXDBDAYS: max age for stored queries is 7 days
[2020-07-20 20:18:18.421 2294M]    RESOLVE_IPV6: Resolve IPv6 addresses
[2020-07-20 20:18:18.421 2294M]    RESOLVE_IPV4: Resolve IPv4 addresses
[2020-07-20 20:18:18.421 2294M]    DBINTERVAL: saving to DB file every minute
[2020-07-20 20:18:18.421 2294M]    DBFILE: Using /etc/pihole/pihole-FTL.db
[2020-07-20 20:18:18.421 2294M]    MAXLOGAGE: Importing up to 12.0 hours of log data
[2020-07-20 20:18:18.421 2294M]    PRIVACYLEVEL: Set to 0
[2020-07-20 20:18:18.421 2294M]    IGNORE_LOCALHOST: Show queries from localhost
[2020-07-20 20:18:18.421 2294M]    BLOCKINGMODE: Null IPs for blocked domains
[2020-07-20 20:18:18.421 2294M]    ANALYZE_ONLY_A_AND_AAAA: Disabled. Analyzing all queries
[2020-07-20 20:18:18.421 2294M]    DBIMPORT: Importing history from database
[2020-07-20 20:18:18.421 2294M]    PIDFILE: Using /run/pihole-FTL.pid
[2020-07-20 20:18:18.421 2294M]    SOCKETFILE: Using /run/pihole/FTL.sock
[2020-07-20 20:18:18.421 2294M]    SETUPVARSFILE: Using /etc/pihole/setupVars.conf
[2020-07-20 20:18:18.421 2294M]    MACVENDORDB: Using /etc/pihole/macvendor.db
[2020-07-20 20:18:18.421 2294M]    GRAVITYDB: Using /etc/pihole/gravity.db
[2020-07-20 20:18:18.421 2294M]    PARSE_ARP_CACHE: Active
[2020-07-20 20:18:18.421 2294M]    CNAME_DEEP_INSPECT: Active
[2020-07-20 20:18:18.421 2294M]    DELAY_STARTUP: No delay requested.
[2020-07-20 20:18:18.421 2294M]    NICE: Set process niceness to -10 (default)
[2020-07-20 20:18:18.421 2294M]    BLOCK_ESNI: Enabled, blocking _esni.{blocked domain}
[2020-07-20 20:18:18.421 2294M]    NAMES_FROM_NETDB: Enabled, trying to get names from network database
[2020-07-20 20:18:18.421 2294M] Finished config file parsing
[2020-07-20 20:18:18.422 2294M] Database version is 6
[2020-07-20 20:18:18.423 2294M] Database successfully initialized
[2020-07-20 20:18:18.423 2294M] New upstream server: 192.168.2.30 (0/1024)
[2020-07-20 20:18:18.424 2294M] New upstream server: 192.168.1.100 (1/1024)
[2020-07-20 20:18:18.426 2294M] Resizing "/FTL-strings" from 4096 to 8192
[2020-07-20 20:18:18.429 2294M] Resizing "/FTL-strings" from 8192 to 12288
[2020-07-20 20:18:18.435 2294M] Resizing "/FTL-strings" from 12288 to 16384
[2020-07-20 20:18:18.448 2294M] Resizing "/FTL-strings" from 16384 to 20480
[2020-07-20 20:18:18.469 2294M] Resizing "/FTL-strings" from 20480 to 24576
[2020-07-20 20:18:18.471 2294M] Resizing "/FTL-queries" from 212992 to 425984
[2020-07-20 20:18:18.492 2294M] Resizing "/FTL-strings" from 24576 to 28672
[2020-07-20 20:18:18.516 2294M] Resizing "/FTL-strings" from 28672 to 32768
[2020-07-20 20:18:18.524 2294M] Resizing "/FTL-queries" from 425984 to 638976
[2020-07-20 20:18:18.552 2294M] New upstream server: 192.168.2.1 (2/1024)
[2020-07-20 20:18:18.554 2294M] Imported 10675 queries from the long-term database
[2020-07-20 20:18:18.554 2294M]  -> Total DNS queries: 10675
[2020-07-20 20:18:18.554 2294M]  -> Cached DNS queries: 2390
[2020-07-20 20:18:18.554 2294M]  -> Forwarded DNS queries: 5487
[2020-07-20 20:18:18.554 2294M]  -> Blocked DNS queries: 2783
[2020-07-20 20:18:18.554 2294M]  -> Unknown DNS queries: 15
[2020-07-20 20:18:18.554 2294M]  -> Unique domains: 1450
[2020-07-20 20:18:18.554 2294M]  -> Unique clients: 13
[2020-07-20 20:18:18.554 2294M]  -> Known forward destinations: 3
[2020-07-20 20:18:18.554 2294M] Successfully accessed setupVars.conf
[2020-07-20 20:18:18.567 2296M] PID of FTL process: 2296
[2020-07-20 20:18:18.568 2296M] Reloading DNS cache
[2020-07-20 20:18:18.568 2296M] Blocking status is enabled
[2020-07-20 20:18:18.569 2296/T2300] Listening on Unix socket
[2020-07-20 20:18:18.571 2296/T2299] Listening on port 4711 for incoming IPv6 telnet connections
[2020-07-20 20:18:18.577 2296/T2298] Listening on port 4711 for incoming IPv4 telnet connections
[2020-07-20 20:18:18.602 2296M] INFO: No regex blacklist entries found
[2020-07-20 20:18:18.602 2296M] INFO: No regex whitelist entries found
[2020-07-20 20:18:18.604 2296M] Compiled 0 whitelist and 0 blacklist regex filters for 13 clients in 7.2 msec
[2020-07-20 20:20:15.730 2296M] Resizing "/FTL-strings" from 32768 to 36864

setupVars.conf:

WEBPASSWORD=
BLOCKING_ENABLED=true
PIHOLE_INTERFACE=ens3
IPV4_ADDRESS=0.0.0.0
IPV6_ADDRESS=
QUERY_LOGGING=true
INSTALL_WEB_SERVER=true
INSTALL_WEB_INTERFACE=true
LIGHTTPD_ENABLED=true
DNSMASQ_LISTENING=single
PIHOLE_DNS_1=192.168.2.30
PIHOLE_DNS_2=192.168.2.1
DNS_FQDN_REQUIRED=true
DNS_BOGUS_PRIV=true
DNSSEC=false
REV_SERVER=false

Any other information that might be missing, please let me know! (pihole.log is quite large, so I didn't post that...)

That's expected behaviour since 5.0:

See also Correct Resolv.conf entry in pihole 5.11 - #2 by jfb, where jfb explains the ins and outs of picking a DNS server for the machine that hosts Pi-hole.

Hey uniqueshort, this is the exact issue I ran into yesterday. While I read in many places that this is expected behaviour, it does seem to prevent the PiHole from ever being able to update itself. None of my apt commands would work.

First thing I did was to temporarily add the PiHole itself as a DNS server, just to get past the Temporary Failure error. I edited /etc/resolv.conf

sudo nano /etc/resolv.conf

I added nameserver 127.0.0.1 right about the .53 line and saved it out. That immediately allowed me to do apt updates. I read a few articles on how to fix it permanently. This one seemed to do it.

How To Set Permanent DNS Nameservers in Ubuntu

Once I did all of that, everything works.

Oh, and after I updated form 5.0 to 5.1.1, none of my graphs and some of the pages seemed all broken. I had to Ctrl+F5 each one of those pages and the force reload fixed every page.

Good luck, and let me know if you have any problems with any of this.

Thanks. I replaced the nameserver in resolv.conf permanently with the local uplink nameserver that pihole is using. That did it for me.

Glad to head it!

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