Pi-hole 4.1 came out recently, but my install is still stuck on 4.0. Running pihole -up doesn’t seem to work because of modifications that DietPi makes to the Pi-hole files and prevents git from fetching the changes from their repo. Do I need to wait for a new DietPi release that includes 4.1 or is there some recommended method to handle updates to Pihole?
root@DietPi:~# pihole -up
[i] Checking for updates...
[i] Pi-hole Core: up to date
[i] Web Interface: update available
[i] FTL: update available
[i] Pi-hole Web Admin files out of date, updating local repo.
[✓] Check for existing repository in /var/www/html/admin
[i] Update repo in /var/www/html/admin...
: Could not update local repository. Contact support.
1 Like
I had this exact same problem, my (hacky) solution was to back up my current pi-hole configuration (whitelist, blacklist etc). Use the dietpi-software utility to uninstall pi-hole and then use the utility to re-install it. After that it was just a couple of minutes to reconfigure it to how I had it before.
A little clunky but at least I ended up with an updated system at the end.
I’m on 6.19.7 and pihole -up worked fine here.
John
Do you use the Web Interface Dashboard?
From the software page
https://dietpi.com/forum/t/dietpi-survey-information/32/1
Updating PiHole:
PiHole overwrites the lighttpd.conf during updates, so please backup your lighttpd.conf before updating:
Backup lighttpd.conf
mv /etc/lighttpd/lighttpd.conf /etc/lighttpd/lighttpd.conf.bak
PiHole can then be updated by running pihole -up
Restore lighttpd.conf
mv /etc/lighttpd/lighttpd.conf.bak /etc/lighttpd/lighttpd.conf
I do
Unfortunately that didn’t work on its own. The issue seems to be that there are modified files in the web folder, however they all just seem to be mode changes.
root@DietPi:~# mv /etc/lighttpd/lighttpd.conf /etc/lighttpd/lighttpd.conf.bak
root@DietPi:~# cd /var/www/html/admin
root@DietPi:/var/www/html/admin# git diff --summary
mode change 100644 => 100755 .github/ISSUE_TEMPLATE.md
... (~100 files like this)
root@DietPi:/var/www/html/admin# git checkout .
root@DietPi:/var/www/html/admin# pihole -up
root@DietPi:~# mv /etc/lighttpd/lighttpd.conf.bak /etc/lighttpd/lighttpd.conf
That worked.
Hi guys, I guess the issue might be related to Pi-hole installs that were 3.X at first.
With Pi-hole 4.X new committed a new option to DietPi to skip webserver install/setup. to allow doing this prior on our own (and in case choose another webserver than lighttpd) and skip overwriting the lighttpd.conf.
If you install a fresh Pi-hole now on DietPi, it will install with this new option and safe it to be applied on pihole -up as well. This should work without issues. But I guess if you started from an earlier version, the required setupVar might be missing, leading to the issue with changed/overwritten lighttpd.conf.
Thanks. My installation started with Pi-hole 4.0 and I had to follow the steps above to upgrade to 4.1 (not sure if the lighttpd.conf step was necessary). I was able to upgrade to 4.1.1 without issue and did not move lighttpd.conf this time around.
Worth noting: after updating to DietPi 6.20, there were file mode changes in
/var/www/html/admin
. I had to run
git checkout .
before
pihole -up
would complete successfully.
We identified the issue and will fix it with v6.22. Check out the quick solution: https://github.com/Fourdee/DietPi/issues/2516