DELAY_STARTUP behavior with the new Pi-hole 5.11

I see in release notes that the latest version will only honor DELAY_STARTUP during boot-up. What does it look at to determine it is a boot-up? I am using a PogoPlug running Debian 10. This device doesn't have a hardware clock, so I have installed fake-hwclock. If the device has been shut down for a few days, date/time could still be off by days until NTP has synced the time. NTP sometimes doesn't finish before FTL starts, so I have DELAY_STARTUP set to 10 seconds to allow NTP to finish before FTL starts.

After updating to the latest pi-hole version, I see this in my log after a reboot:

[2022-06-29 15:39:30.039 1635M] Finished config file parsing
[2022-06-29 15:39:30.039 1635M] Not sleeping as system has finished booting

So, it didn't delay 10 seconds to allow NTP to finish, which means FTL is started with the wrong system time. This was today, July 9th, so time is off by days (note that, as a test, I manually modified /etc/fake-hwclock.data to force this condition). This, of course, then results in this error:

[2022-07-09 15:01:26.316 1636M] WARN: Found database entries in the future (2022-07-09 15:05:00 (1657397100), last timestamp for importing: 2022-06-09 14:55:00 (1654804500)). Your over-time statistics may be incorrect (found in src/dnsmasq_interface.c:671)

What do I need to do to insure it honors the DELAY_STARTUP setting on bootup?

Ralph

Within the new behavior, DELAY_STARTUP is only honored within 60 seconds after the system started. It checks the reported uptime from the system. If 60 seconds are elapsed, the DELAY_STARTUP won't be honored. The idea was that we expect only a necessary delay after a fresh start, not if Pi-hole is restarted later.
Currently, you can't do anything about it, the 60 seconds are hard-coded. (Of course you could change that flag and compile yourself). I agree, this could get some tweaking.

Thanks yubiuser. Yeah, if it could be changed to 120 or 180 seconds, it would still accomplish what you're trying to do while allowing those of us with low-powered systems that can take more than 60 seconds to boot to delay FTL startup when needed.

Is that something I should make a request for, or will it be considered based on this thread?

What system are you running that takes more than 60 seconds to boot?

It's a PogoPlug Pogo-V4-A1-01. Single 800 MHz armel processor.

That is a particularly slow device, slower than any Pi that I am aware of.

Yes. It's similar to the original single-core Raspberry pi. But there are a number of people running pi-hole on these devices.

We'll discuss this internally, no need for additional requests.

OK, thank you.

Just to note that I too have 3 different Pogoplug devices that I run Pi-hole on, including this one. I will follow this thread to see the final conclusion.

Just an update - on my Pogo-V4-A1-01, the pi-hole startup is happening at very close to the 60-second mark, so sometimes DELAY_STARTUP is working, sometimes it's not. Changing the "still booting" threshold to 120 seconds should definitely be enough time for DELAY_STARTUP to work reliably.

I'm fine to err on the side of caution here

Hi bluzfanmr1. Just curious - are you running Debian 9 or Debian 10 on your Pogoplug? I just updated to 10 since this version of pi-hole wants at least 10, and now I am having problems saving config changes via web interface.

I can see these errors in /var/log/lighttpd/error.log

2022-07-20 22:20:21: (mod_fastcgi.c.421) FastCGI-stderr: PHP Warning: Executing sudo pihole -a -i single -web failed. in /var/www/html/admin/scripts/pi-hole/php/func.php on line 150
2022-07-20 22:20:21: (mod_fastcgi.c.421) FastCGI-stderr: PHP Warning: Executing sudo pihole -a ratelimit 1000 60 false failed. in /var/www/html/admin/scripts/pi-hole/php/func.php on line 150
2022-07-20 22:20:21: (mod_fastcgi.c.421) FastCGI-stderr: PHP Warning: Executing sudo pihole -a setdns "8.8.8.8,8.8.4.4,208.67.222.222,208.67.220.220" domain-needed bogus-priv no-dnssec failed. in /var/www/html/admin/scripts/pi-hole/php/func.php on line 150

and this error in my syslog

Jul 20 22:20:20 pihole authpriv.alert sudo: www-data : account validation failure, is your account locked? ; TTY=unknown ; PWD=/var/www/html/admin ; USER=root ; COMMAND=/usr/local/bin/pihole -a -i single -web
Jul 20 22:20:21 pihole authpriv.alert sudo: www-data : account validation failure, is your account locked? ; TTY=unknown ; PWD=/var/www/html/admin ; USER=root ; COMMAND=/usr/local/bin/pihole -a ratelimit 1000 60 false
Jul 20 22:20:21 pihole authpriv.alert sudo: www-data : account validation failure, is your account locked? ; TTY=unknown ; PWD=/var/www/html/admin ; USER=root ; COMMAND=/usr/local/bin/pihole -a setdns 8.8.8.8,8.8.4.4,208.67.222.222,208.67.220.220 domain-needed bogus-priv no-dnssec

But I can't quite figure out what's broken.

I have Pi-hole running on both a Pogoplug E02 and on a Pogoplug Pro and I don't see those messages on either one. I have been running Debian 10 on the E02 for awhile. I did have to upgrade the Pro to Debian 10 so I could upgrade to the latest Pi-hole release.

That being said, I have also been unable to save any changes to the web interface on the E02 for quite awhile, though it seems to run just fine with the settings I enabled at install. I could not get it to take the conditional forwarding settings though.

Also, with this latest upgrade to Debian 10 and the new version of Pi-hole, I am also unable to make any web interface changes on the Pro.

I hadn't had time to try and chase it down. Maybe someone here has an idea what might be the issue or if you find anything out, let me know.

I think I figured it out. I did a fresh install of Debian 11 and installed pi-hole, but still same issue.

The error message mentions the account being locked, so I tried "usermod -U www-data", but that had no effect. So, on a hunch, I added this to /etc/shadow, below the "root" entry (I don't know if order matters, but that's the relative order that www-data exists in my /etc/passwd)

www-data:!:::::::

Tried saving settings, and voila - they worked. I guess the usermod won't add a "locked" entry to /etc/shadow, it'll only lock one that's already there.

Hope that fixes it for you too.

THANK YOU!!! That worked for both of my Pogoplug's! I really appreciate you tracking it down!

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