@bluzfanmr1 my pihole is also running a cloudflare tunnel to facilitate dns-over-https. This lead to swapping out "parts" from pihole causing the system to become very slow. Deactivating swap solved this, but then my system ran out of memory every now and then causing it to crash. So as already mentioned, I played around with swappiness, and setting it at 8 seems to solve the "slow system".
In /etc/sysctl.conf add:
vm.swappiness=8
Also added this:
vm.panic_on_oom=1
kernel.panic=10
Because last night I could not ping the device anymore after running fine for a week or so
Anyway, what kernel are you running on the device?
Mine is running Linux pogo01 5.15.158-oxnas-tld-2 #2 SMP PREEMPT Sun May 12 18:45:05 PDT 2024 armv6l GNU/Linux
Thanks for the tips, I will check them out! I have swappiness set to 60 on the recommendation over at the Doozan forums:
# increase the free page caches for VM
vm.min_free_kbytes = 16384
vm.swappiness = 60
I'll play around a bit and look for improvement.
As far as kernel, I'm still on an older kernel:
Linux PogoplugPro2 4.14.198-oxnas-tld-1 #1 SMP PREEMPT Sun Sep 20 22:15:05 PDT 2020 armv6l GNU/Linux
I have never been able to get to the 5.xx.xx kernel version with my Pro. I have tried and tried but there is something weird that keeps it from working. Even totally from scratch.
My other pogoplug with pihole v5 is also running that kernel and I have never seen it crash. Gonna switch to that one again during the weekend.
Thanks for the update.
In regards to my issues with pihole v5, I found the problem, it seems.
There was a problem with user "www-data". This user had an entry in /etc/passwd, but did not have an entry in /etc/shadow.
Once I fixed that, the webif is working normally.
The bigger question is why this is not working out-of-the-box. I'm not sure when Debian creates the www-data user, and why there was no entry in /etc/shadow for said user. I don't know if it is a script/function in apt/dpkg in Debian, in the install of lighttpd, that creates the www-data user and sets up both /etc/passwd and /etc/shadow - I'm doubting that www-data should be a default user and group in a minimal rootfs... seems like it would only be added in for software packages that require it.
I may try to create a fresh rootfs from debootstrap and see what exactly is going on that caused this problem.
==========
Also, I successfully compiled v6 (v5.25.2-2341-g91ea8d49) both natively on the pogoplug V2, as well as in a chroot (with qemu) environment on my intel 64 bit workstation. Native compilation (the dependencies and pihole-FTL) took about 2+ hrs, and on the workstation, much less.
Still need to get some problems worked out for the v6 ... they may be caused by permissions/user issues also.
I'm not sure... did you try to install Apache or a different web server any time before installing Pi-hole? I think this user is created when you install a web server.
It was a pristine/fresh rootfs that I used. No web server installed before running the standard install script for Pihole (which did, of course, install lighttpd).
I'm wondering if there is something in the ordering of the installations that could be the issue. Or if something like the "locales" package (or the lack of its preconfiguration) that could trigger a problem in the install.
In the rootfs that "we" < meaning the community of Debian Kirkwood users at Doozan Forums > use, the "locale" and "language" is not set... that may be upsetting to libpcre (which is a dependency which is a dependency for lighttpd, IIRC).
I'm not sure if Bodhi's rootfs have the base-passwd package installed. It is counterintuitive, but docs say that the webserver packages in Debian **do not ** add in the www-data user and group.
I believe the www-data user comes default OOTB with a basic Debian install.
Below is also from a (minbase) debootstrapped Debian with no web daemon installed:
Looks like the base-passwd package is responsible for that:
$ apt show base-passwd
[..]
Description: Debian base system master password and group files
These are the canonical master copies of the user database files
(/etc/passwd and /etc/group), containing the Debian-allocated user and
group IDs. The update-passwd tool is provided to keep the system databases
synchronized with these master files.
$ less /usr/share/doc/base-passwd/README
base-passwd for Debian
----------------------
This package supplies the "master" copies of /etc/passwd and /etc/group,
in /usr/share/base-passwd.
[..]
* the home directory for the www-data user is preserved
Thanks @deHakkelaar for that confirmation...that is my understanding also. OOTB in this case means (to me) "with update-passwd installed and working correctly".
I will try to test this by creating a rootfs from scratch.
$ man debootstrap
[..]
--variant=minbase|buildd|fakechroot
Name of the bootstrap script variant to use. Cur‐
rently, the variants supported are minbase, which only
includes required packages and apt; buildd, which in‐
stalls the build-essential packages and fakechroot,
which installs the packages without root privileges.
The default, with no --variant=X argument, is to cre‐
ate a base Debian installation with all packages of
priority required and important, including apt.