DNS is randomly crashing

Please follow the below template, it will help us to help you!

If you are Experiencing issues with a Pi-hole install that has non-standard elements (e.g you are using nginx instead of lighttpd, or there is some other aspect of your install that is customised) - please use the Community Help category.

Expected Behaviour:

Pihole DNS doesn't crash

Actual Behaviour:

I'm getting random crashes of the DNS service. When it happens, I can log into the UI, restart DNS, and its fine. Until it crashes again. Sometimes it lasts a day, sometimes its an hour.

Debug Token:

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

It's a little difficult to see what may be going on because it looks like the log files are being created new when you restart instead of continuing on:

-rw-r--r-- 1 pihole pihole 14926 Jun 18 13:39 /var/log/pihole-FTL.log
   -----head of pihole-FTL.log------
   [2021-06-18 10:38:11.803 961M] Using log file /var/log/pihole-FTL.log
   [2021-06-18 10:38:11.803 961M] ########## FTL started! ##########
   [2021-06-18 10:38:11.803 961M] FTL branch: master
   [2021-06-18 10:38:11.803 961M] FTL version: v5.8.1
   [2021-06-18 10:38:11.803 961M] FTL commit: b90ab8b1
   [2021-06-18 10:38:11.803 961M] FTL date: 2021-04-21 20:03:47 +0100
   [2021-06-18 10:38:11.803 961M] FTL user: pihole
   [2021-06-18 10:38:11.803 961M] Compiled for armv7hf (compiled on CI) using arm-linux-gnueabihf-gcc (Debian 6.3.0-18) 6.3.0 20170516
   [2021-06-18 10:38:11.804 961M] Creating mutex
   [2021-06-18 10:38:11.806 961M] Starting config file parsing (/etc/pihole/pihole-FTL.conf)

Normally we'd see something about a shutdown or the end of the previous logging and then a new start up process. This looks like the entire device was restarted or the /var/log directory was wiped.

In testing, I had restarted it. Of course, its now been running without issue since then. Here's another token, but I assume you really need one after it dies?

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

Can you explain exactly what you did when you restarted it? Do you mean you restarted the whole device with a reboot?

Do you have your /var/log set up as a ramlog or anything that would wipe that directory?

Explanation for what I mean when I say the log was not complete. Normally we'd see some activity before the startup from the previous daemon that was running, like below:

dan@raspberrypi:/var/log $ cat pihole-FTL.log
[2021-06-19 19:06:00.534 668M] Shutting down...
[2021-06-19 19:06:00.785 668M] Finished final database update
[2021-06-19 19:06:00.785 668M] Waiting for threads to join
[2021-06-19 19:06:00.785 668M] Thread telnet-IPv4 (0) is idle, terminating it.
[2021-06-19 19:06:00.786 668M] Thread telnet-IPv6 (1) is idle, terminating it.
[2021-06-19 19:06:00.786 668M] Thread telnet-socket (2) is idle, terminating it.
[2021-06-19 19:06:00.786 668M] Thread database (3) is idle, terminating it.
[2021-06-19 19:06:00.786 668M] Thread housekeeper (4) is idle, terminating it.
[2021-06-19 19:06:00.787 668M] Thread DNS client (5) is idle, terminating it.
[2021-06-19 19:06:00.787 668M] All threads joined
[2021-06-19 19:06:00.797 668M] ########## FTL terminated after 48d 22h 1m 11s  (code 0)! ##########
[2021-06-19 19:06:01.795 23734M] Using log file /var/log/pihole-FTL.log
[2021-06-19 19:06:01.795 23734M] ########## FTL started! ##########
[2021-06-19 19:06:01.795 23734M] FTL branch: master
[2021-06-19 19:06:01.795 23734M] FTL version: v5.8.1
[2021-06-19 19:06:01.795 23734M] FTL commit: b90ab8b1
[2021-06-19 19:06:01.795 23734M] FTL date: 2021-04-21 20:03:47 +0100
[2021-06-19 19:06:01.795 23734M] FTL user: pihole
[2021-06-19 19:06:01.795 23734M] Compiled for armv7hf (compiled on CI) using arm-linux-gnueabihf-gcc (Debian 6.3.0-18) 6.3.0 20170516
[2021-06-19 19:06:01.795 23734M] Creating mutex
[2021-06-19 19:06:01.797 23734M] Starting config file parsing (/etc/pihole/pihole-FTL.conf)

If it crashed then we'd expect to see something that didn't say "Shutting down", just the tail of the previous logging and then a new start, like below (just an example, ignore the timestamps since I copy/pasted from a couple of different sections to make this look like a crash):

[2021-06-19 19:06:02.460 23734M] Resizing "FTL-domains" from 32768 to (2304 * 16) == 36864 (/dev/shm: 5.0MB used, 978.1MB total, FTL uses 5.0MB)
[2021-06-19 19:06:02.506 23734M] Resizing "FTL-queries" from 4128768 to (77824 * 56) == 4358144 (/dev/shm: 5.0MB used, 978.1MB total, FTL uses 5.0MB)
[2021-06-19 19:06:02.547 23734M] Resizing "FTL-queries" from 4358144 to (81920 * 56) == 4587520 (/dev/shm: 5.3MB used, 978.1MB total, FTL uses 5.3MB)
[2021-06-19 19:06:02.590 23734M] Resizing "FTL-domains" from 36864 to (2560 * 16) == 40960 (/dev/shm: 5.5MB used, 978.1MB total, FTL uses 5.5MB)
[2021-06-19 19:06:02.601 23734M] Resizing "FTL-queries" from 4587520 to (86016 * 56) == 4816896 (/dev/shm: 5.5MB used, 978.1MB total, FTL uses 5.5MB)
[2021-06-19 19:06:01.795 23734M] ########## FTL started! ##########
[2021-06-19 19:06:01.795 23734M] FTL branch: master
[2021-06-19 19:06:01.795 23734M] FTL version: v5.8.1
[2021-06-19 19:06:01.795 23734M] FTL commit: b90ab8b1
[2021-06-19 19:06:01.795 23734M] FTL date: 2021-04-21 20:03:47 +0100
[2021-06-19 19:06:01.795 23734M] FTL user: pihole
[2021-06-19 19:06:01.795 23734M] Compiled for armv7hf (compiled on CI) using arm-linux-gnueabihf-gcc (Debian 6.3.0-18) 6.3.0 20170516
[2021-06-19 19:06:01.795 23734M] Creating mutex
[2021-06-19 19:06:01.797 23734M] Starting config file parsing (/etc/pihole/pihole-FTL.conf)

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