Temporary Failure in Name Resolution

Context:

DNS Resolution worked as expected both localhost and clients until this morning when, due to weather, there were several power "blips" that caused the RPi-4 to reboot multiple times.

Expected Behaviour:

DNS resolution from the localhost (pi-hole) RPi-4 should work for functions such as "apt-get" and the like.

Actual Behaviour:

DNS lookups are failing with "Temporary failure in Name Resolution"

Debug Token:

https://tricorder.pi-hole.net/q70bpm9jq3

I searched and found one relevant issue that also had a good outcome:
https://discourse.pi-hole.net/t/dns-issue-temporary-failure-in-name-resolution/19753

Using the hints provided, I can get DNS to resolve from shell by editing /etc/resolv.conf and using a Public DNS server such as 1.1.1.1.

However, I cannot get DNS to resolve with the auto-generated 127.0.0.1 or the IP address of eth0 10.1.10.3.

I do use Unbound DNS on 127.0.1.1#53001 and localhost $ dig @127.0.1.1 -p 53001 resolves as expected.

DNS clients in my home network also resolve as expected to the Private IP (10.1.10.3).

Side note: Queries and Clients line graphs on the Admin page have also stopped showing any activity - maybe related? Maybe it got corrupted?

I'd really prefer not to wipe and start over, suggestions? Further debug data?

Have you checked that the time on the Pi is correct? Power losses frequently result in incorrect time, since the Pi does not have an internal clock. Incorrect time can interfere with DNSSEC authentication.

Also, I note that you have DNSSEC enabled on the Pi, and it is most likely also enabled on both of your recursive resolvers (unbound and knot). Disable DNSSEC on the Pi-Hole and leave DNSSEC to the authoritative resolvers.

Your debug log also shows some errors writing to the SQL database. This may be related to power loss as well.

   [2019-10-24 17:38:00.033 1142] SQLite3 message: statement aborts at 34: [INSERT INTO queries VALUES (NULL,?,?,?,?,?,?)] attempt to write a readonly database (8)
   [2019-10-24 17:38:00.033 1142] save_to_DB() - SQL error (8): attempt to write a readonly database
   [2019-10-24 17:38:00.043 1142] SQLite3 message: statement aborts at 34: [INSERT INTO queries VALUES (NULL,?,?,?,?,?,?)] attempt to write a readonly database (8)
   [2019-10-24 17:38:00.043 1142] save_to_DB() - SQL error (8): attempt to write a readonly database
   [2019-10-24 17:38:00.043 1142] SQLite3 message: statement aborts at 34: [INSERT INTO queries VALUES (NULL,?,?,?,?,?,?)] attempt to write a readonly database (8)
   [2019-10-24 17:38:00.043 1142] save_to_DB() - SQL error (8): attempt to write a readonly database
   [2019-10-24 17:38:00.043 1142] save_to_DB() - exiting due to too many errors
   [2019-10-24 17:38:00.045 1142] SQLite3 message: statement aborts at 22: [UPDATE network SET lastQuery = MAX(lastQuery, 1571891500) WHERE id = 2;] attempt to write a readonly database (8)
   [2019-10-24 17:38:00.045 1142] dbquery(UPDATE network SET lastQuery = MAX(lastQuery, 1571891500) WHERE id = 2;) - SQL error (8): attempt to write a readonly database
   [2019-10-24 17:38:00.045 1142] check_database(8): Disabling database connection due to error
   [2019-10-24 17:38:00.045 1142] SQLite3 message: statement aborts at 21: [UPDATE network SET numQueries = numQueries + 380 WHERE id = 2;] attempt to write a readonly database (8)
   [2019-10-24 17:38:00.046 1142] dbquery(UPDATE network SET numQueries = numQueries + 380 WHERE id = 2;) - SQL error (8): attempt to write a readonly database
   [2019-10-24 17:38:00.046 1142] check_database(8): Disabling database connection due to error

Time seems to be good:

$ ntpdate -q 0.us.pool.ntp.org
server 66.7.96.2, stratum 2, offset 0.004120, delay 0.07628
server 71.114.67.173, stratum 1, offset -0.002697, delay 0.08261
server 162.159.200.1, stratum 3, offset -0.000328, delay 0.03603
server 184.105.182.7, stratum 2, offset -0.000948, delay 0.06204
25 Oct 07:32:36 ntpdate[11431]: adjust time server 71.114.67.173 offset -0.002697 sec

The database bit is concerning - is there a preferred method to rebuild /re-initialize the database? I did a search in forum and general internet and didn't spot anything that seemed useful...

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