Continuing the discussion from Keeps falling back to "Pi-hole blocking is Disabled":
Please follow the below template, it will help us to help you!
Pi-Hole should remain Enabled when running.
Immediately after toggling to Enabled, Pi-Hole switches back to Disabled.
As we tracked down the last time this happened, this is due to duplicate "BLOCKING_ENABLED" entries in setupVars.conf, one set True and one set False.
The question is, how did I end up with two entries? This time around, it's a completely different install on a virtual machine (previous install was on a Pi3). The settings I'm using are the same, the only unique customization (with both installs) is that I implemented DNS-over-HTTPS following the guide here: https://docs.pi-hole.net/guides/dns-over-https/
I've looked at the source code and it really doesn't seem like there's any way this entry could be duplicated in any of the blocks that actually touch BLOCKING_ENABLED directly, unless the
sed somehow fails? https://github.com/pi-hole/pi-hole/blob/9e490775ff3b20f378acc9db7cec2ae6023fff7f/pihole#L191-L212
Permissions on setupVars.conf:
-rw-r--r-- 1 root root 654 May 8 17:09 /etc/pihole/setupVars.conf
This time, it looks like it happened after a spontaneous reboot. Not sure (yet) what caused the reboot. I also don't remember if the previous incident occurred after a reboot.