Beaglebone - DNS will not start after update

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

Expected Behaviour:

Pi-Hole continues to work after update.

Actual Behaviour:

Pi-Hole does not work after update. I can see the webpage but FTL and DNS are dead. I began some steps to install OpenHab but never ran the installer, only updated apt-get items. I had a grand ol’ time getting Pi Hole working the first time around as documented here: https://www.andersknelson.com/blog/?p=559.

Debug Token:

[✓] Your debug token is: https://tricorder.pi-hole.net/g7k1b28njy

What are the outputs of the following commands from the Linux terminal:

sudo netstat -nltup | grep 'Proto\|:53 \|:5053 \|:5353 \|:8953 \|:67 \|:80 \|:471'

sudo service pihole-FTL status

debian@beaglebone:~$ sudo netstat -nltup | grep 'Proto\|:53 \|:5053 \|:5353 \|:8953 \|:67 \|:80 \|:471'
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN      6327/lighttpd
tcp6       0      0 :::80                   :::*                    LISTEN      6327/lighttpd
udp        0      0 0.0.0.0:5353            0.0.0.0:*                           1042/avahi-daemon:
udp6       0      0 :::5353                 :::*                                1042/avahi-daemon:
debian@beaglebone:~$ sudo service pihole-FTL status
● pihole-FTL.service - LSB: pihole-FTL daemon
   Loaded: loaded (/etc/init.d/pihole-FTL; generated; vendor preset: enabled)
   Active: active (exited) since Tue 2020-01-28 05:02:49 UTC; 20h ago
     Docs: man:systemd-sysv-generator(8)
  Process: 7000 ExecStop=/etc/init.d/pihole-FTL stop (code=exited, status=0/SUCCESS)
  Process: 7007 ExecStart=/etc/init.d/pihole-FTL start (code=exited, status=0/SUCCESS)
    Tasks: 0 (limit: 4915)
   CGroup: /system.slice/pihole-FTL.service

Jan 28 05:02:49 beaglebone systemd[1]: Starting LSB: pihole-FTL daemon...
Jan 28 05:02:49 beaglebone pihole-FTL[7007]: Not running
Jan 28 05:02:49 beaglebone su[7036]: Successful su for pihole by root
Jan 28 05:02:49 beaglebone su[7036]: + ??? root:pihole
Jan 28 05:02:49 beaglebone su[7036]: pam_unix(su:session): session opened for user pihole by (uid=0)
Jan 28 05:02:49 beaglebone pihole-FTL[7007]: dnsmasq: illegal repeated keyword at line 33 of /etc/dnsmasq.d/0
Jan 28 05:02:49 beaglebone systemd[1]: Started LSB: pihole-FTL daemon.
lines 1-16/16 (END)
debian@beaglebone:/etc/dnsmasq.d$ cat 01-pihole.conf
# Pi-hole: A black hole for Internet advertisements
# (c) 2017 Pi-hole, LLC (https://pi-hole.net)
# Network-wide ad blocking via your own hardware.
#
# Dnsmasq config for Pi-hole's FTLDNS
#
# This file is copyright under the latest version of the EUPL.
# Please see LICENSE file for your rights under this license.

###############################################################################
#      FILE AUTOMATICALLY POPULATED BY PI-HOLE INSTALL/UPDATE PROCEDURE.      #
# ANY CHANGES MADE TO THIS FILE AFTER INSTALL WILL BE LOST ON THE NEXT UPDATE #
#                                                                             #
#        IF YOU WISH TO CHANGE THE UPSTREAM SERVERS, CHANGE THEM IN:          #
#                      /etc/pihole/setupVars.conf                             #
#                                                                             #
#        ANY OTHER CHANGES SHOULD BE MADE IN A SEPARATE CONFIG FILE           #
#                    WITHIN /etc/dnsmasq.d/yourname.conf                      #
###############################################################################

addn-hosts=/etc/pihole/gravity.list
addn-hosts=/etc/pihole/black.list
addn-hosts=/etc/pihole/local.list


localise-queries


no-resolv



cache-size=10000

log-queries
log-facility=/var/log/pihole.log

local-ttl=2

log-async
server=8.8.8.8
server=8.8.4.4
interface=eth0

This is the problem. The file name was cut off but it was likely 01-pihole.conf. Line 33 of this file is

cache-size=10000

There is likely another cache size entry in a separate dnsmasq configuration file. Let’s look. What is the output of the following:

ls -lha /etc/dnsmasq.d

cat /etc/dnsmasq.conf

sudo grep cache-size -R /etc/dnsmasq.d

Thanks for the support, here’s the output:

debian@beaglebone:~$ ls -lha /etc/dnsmasq.d
total 16K
drwxr-xr-x   2 root root 4.0K Jan 29 01:57 .
drwxr-xr-x 109 root root 4.0K Jan 29 03:18 ..
-rw-r--r--   1 root root 1.4K Jan 29 01:57 01-pihole.conf
-rw-r--r--   1 root root  391 Jan 29 03:18 SoftAp0

debian@beaglebone:~$ cat /etc/dnsmasq.conf
conf-dir=/etc/dnsmasq.d

debian@beaglebone:~$ sudo grep cache-size -R /etc/dnsmasq.d
/etc/dnsmasq.d/SoftAp0:cache-size=2048
/etc/dnsmasq.d/01-pihole.conf:cache-size=10000

This is the problem. SoftAp0 has created a conflicting cache-size statement. Remove the SoftAp0 configuration file and start FTL with

sudo service pihole-FTL start

I commented the line “cache-size=2048”, shouldn’t that be enough?

debian@beaglebone:/etc/dnsmasq.d$ sudo service pihole-FTL start
debian@beaglebone:/etc/dnsmasq.d$ pihole status
  [✗] DNS service is NOT running
debian@beaglebone:/etc/dnsmasq.d$ cat SoftAp0
interface=usb0
interface=usb1
port=53
dhcp-authoritative
domain-needed
bogus-priv
expand-hosts
#cache-size=2048
dhcp-range=usb0,192.168.7.1,192.168.7.1,2m
dhcp-range=usb1,192.168.6.1,192.168.6.1,2m
listen-address=127.0.0.1
listen-address=192.168.7.2
listen-address=192.168.6.2
dhcp-option=usb0,3
dhcp-option=usb0,6
dhcp-option=usb1,3
dhcp-option=usb1,6
dhcp-leasefile=/var/run/dnsmasq.leases

You should get rid of the entire configuration file to get Pi-Hole running. You’ll be chasing conflicts line by line otherwise. Some related threads on this issue.

Haha, owned by my own troubleshooting post! I’m not even mad, that’s amazing.

Removed SoftAp0, rebooted.

debian@beaglebone:~$ pihole status
[sudo] password for debian:
  [✓] DNS service is running
  [✓] Pi-hole blocking is Enabled

Time to donate again, thanks!

Heyoo, FYI the Beaglebone Black BSP loves to regenerate the SoftAp0 file whenever you reboot! You can solve that issue here:

https://groups.google.com/forum/#!topic/beagleboard/H1rFzlj6rV0

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