Pi-hole DNS not running

Issue

I have a Pi-hole install the is constantly saying DNS not running. After DNS is restarted the service works for a while but then it stops working. Any help I would really appreciate. I know my ubuntu version is not supported but I have exactly the same setup in another server and it is currently working

Debug Token:

Here is the debug token
Can you help @yubiuser ?

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

Additional Comands

ubuntu@lea:~$ sudo netstat -ltunp | grep ":53 "
ubuntu@lea:~$ pihole-FTL dnsmasq-test
dnsmasq: syntax check OK.
ubuntu@lea:~$ sudo grep -v '#\|^$' -R /etc/dnsmasq.*
/etc/dnsmasq.conf:conf-dir=/etc/dnsmasq.d
/etc/dnsmasq.conf.old:conf-dir=/etc/dnsmasq.d
/etc/dnsmasq.d/01-pihole.conf:addn-hosts=/etc/pihole/local.list
/etc/dnsmasq.d/01-pihole.conf:addn-hosts=/etc/pihole/custom.list
/etc/dnsmasq.d/01-pihole.conf:localise-queries
/etc/dnsmasq.d/01-pihole.conf:no-resolv
/etc/dnsmasq.d/01-pihole.conf:cache-size=10000
/etc/dnsmasq.d/01-pihole.conf:log-queries
/etc/dnsmasq.d/01-pihole.conf:log-facility=/var/log/pihole.log
/etc/dnsmasq.d/01-pihole.conf:local-ttl=2
/etc/dnsmasq.d/01-pihole.conf:log-async
/etc/dnsmasq.d/01-pihole.conf:server=1.1.1.3
/etc/dnsmasq.d/01-pihole.conf:server=1.0.0.3
/etc/dnsmasq.d/01-pihole.conf:interface=eth0
/etc/dnsmasq.d/01-pihole.conf:server=/use-application-dns.net/
ubuntu@lea:~$ 


### Additional information
ubuntu@lea:~$ pihole restartdns reload
  [✗] /usr/local/bin/pihole: line 162: kill: (786) - No such process
ubuntu@lea:~$ pihole restartdns 
  [✓] Restarting DNS server
ubuntu@lea:~$

Running an unsupported OS is the least of your problem:

/var/www/html/admin/api_db.php on line 402
   2021-08-19 13:38:43: mod_fastcgi.c.487) FastCGI-stderr:PHP Warning:  SQLite3::query(): Unable to prepare statement: 1, no such table: message in /var/www/html/admin/api_db.php on line 402
   2021-08-19 13:38:44: mod_fastcgi.c.487) FastCGI-stderr:PHP Warning:  SQLite3::query(): Unable to prepare statement: 1, no such 

-----head of pihole-FTL.log------
   [2021-08-20 00:01:00.143 786/T790] SQLite3 message: no such table: network_addresses in "DELETE FROM network_addresses WHERE lastSeen < 1597896060;" (1)
   [2021-08-20 00:01:00.143 786/T790] ERROR: SQL query "DELETE FROM network_addresses WHERE lastSeen < 1597896060;" failed: SQL logic error
   [2021-08-20 00:01:00.143 786/T790] SQLite3 message: API call with invalid database connection pointer (21)
   [2021-08-20 00:01:00.144 786/T790] SQLite3 message: misuse at line 165242 of [5d4c65779d] (21)
   [2021-08-20 00:01:00.144 786/T790] Error while trying to close database: bad parameter or other API misuse
   [2021-08-20 00:02:00.237 786/T790] SQLite3 message: no such table: network_addresses in "DELETE FROM network_addresses WHERE lastSeen < 1597896120;" (1)
   [2021-08-20 00:02:00.237 786/T790] ERROR: SQL query "DELETE FROM network_addresses WHERE lastSeen < 1597896120;" failed: SQL logic error
   [2021-08-20 00:02:00.238 786/T790] SQLite3 message: API call with invalid database connection pointer (21)
   [2021-08-20 00:02:00.238 786/T790] SQLite3 message: misuse at line 165242 of [5d4c65779d] (21)

[2021-08-20 06:05:00.056 786/T790] WARN: Command "ip neigh show" failed!
   [2021-08-20 06:05:00.057 786/T790]       Message: Success

I remember I have seen the last two lines before:

Taken together it is very likely that your /etc/pihole/pihole-FTL.db is corrupted, probably even more places on your file system.

I would go for the nuclear option and delete the database as described here. If the errors return, it's time for a new SD card.

@yubiuser Thanks. I just did as you suggested. This PI is brand new so is the SD card.
Let's see what happens. I will continue monitoring. Anything else you think I should do in the mean time?

ubuntu@lea:~$ pihole status
  [✓] DNS service is listening
     [✓] UDP (IPv4)
     [✓] TCP (IPv4)
     [✓] UDP (IPv6)
     [✓] TCP (IPv6)

  [✓] Pi-hole blocking is enabled
ubuntu@lea:~$ sudo service pihole-FTL stop
ubuntu@lea:~$ sudo rm /etc/pihole/pihole-FTL.db
ubuntu@lea:~$ ls -la /etc/pihole/pihole-FTL.db
ls: cannot access '/etc/pihole/pihole-FTL.db': No such file or directory
ubuntu@lea:~$ sudo service pihole-FTL start
ubuntu@lea:~$ pihole status
  [✓] DNS service is listening
     [✓] UDP (IPv4)
     [✓] TCP (IPv4)
     [✓] UDP (IPv6)
     [✓] TCP (IPv6)

  [✓] Pi-hole blocking is enabled
ubuntu@lea:~$

Thanks again!

No, enjoy less ads.

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