MichaIng / DietPi

Lightweight justice for your single-board computer!
https://dietpi.com/
GNU General Public License v2.0
4.8k stars 494 forks source link

Quartz64 | BPF syscalls and cgroup missing, breaking Docker #5890

Closed am9zZWY closed 1 year ago

am9zZWY commented 1 year ago

Details:

root@DietPi:/boot# ls -lrt
total 35920
-rw-r--r-- 1 root root    15251 Oct 22 23:50 dietpi-README.md
-rw-r--r-- 1 root root    18092 Oct 22 23:50 dietpi-LICENSE.txt
-rw-r--r-- 1 root root 36657664 Nov 12 20:48 vmlinuz
-rw-r--r-- 1 root root    54806 Nov 12 20:48 rk3566-quartz64-a.dtb
drwxr-xr-x 2 root root     4096 Nov 12 21:11 u-boot
drwxr-xr-x 2 root root     4096 Nov 12 21:11 extlinux
drwxr-xr-x 4 root root     4096 Nov 16 19:50 dietpi
-rw-r--r-- 1 root root    16013 Nov 16 20:22 dietpi.txt
Joulinar commented 1 year ago

might be similar to this one https://github.com/MichaIng/DietPi/issues/5886

MichaIng commented 1 year ago

Probably not exactly the same, but of similar kind, actually more similar to: #5554

Does it work to append systemd.unified_cgroup_hierarchy=0 to the last line of /boot/extlinux/extlinux.conf?

MichaIng commented 1 year ago

MR up: https://gitlab.com/pgwipeout/quartz64_ci/-/merge_requests/5 But Peter hasn't been responsive to my other MR's so far, so no guarantee šŸ˜‰.

MichaIng commented 1 year ago

Do I have to restart the system after the change?

yes

am9zZWY commented 1 year ago

No, it didn't help

MichaIng commented 1 year ago

Can you show the file content:

cat /boot/extlinux/extlinux.conf

And is the error message the same, or a different one?

am9zZWY commented 1 year ago
root@DietPi:~# cat /boot/extlinux/extlinux.conf
default l0
menu title Quartz64 boot menu
prompt 0
timeout 10

label l0
menu label Boot primary OS
linux /boot/vmlinuz
fdt /boot/rk3566-quartz64-a.dtb
append earlycon=uart8250,mmio32,0xfe660000 console=ttyS2,1500000n8 console=tty1 root=PARTUUID=e28ca6fa-01 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0
systemd.unified_cgroup_hierarchy=0

The error message is the same

MichaIng commented 1 year ago

The settings needs to be "appended to the last line" and not added as new line šŸ˜‰:

default l0
menu title Quartz64 boot menu
prompt 0
timeout 10

label l0
menu label Boot primary OS
linux /boot/vmlinuz
fdt /boot/rk3566-quartz64-a.dtb
append earlycon=uart8250,mmio32,0xfe660000 console=ttyS2,1500000n8 console=tty1 root=PARTUUID=e28ca6fa-01 rootfstype=ext4 rootwait fsck.repair=yes net.ifnames=0 systemd.unified_cgroup_hierarchy=0
am9zZWY commented 1 year ago

Omg! Yeah it works šŸŽ‰

MichaIng commented 1 year ago

Okay great. So same as with Tinker Board, we can either add this OOTB to both boards' boot settings, or we add it whenever Docker or K3s is installed. We already add this when a too low kernel version is detected, so this seems to be a good hook to minimise possible other negative impacts of forcing legacy cgroupv1.

MichaIng commented 1 year ago

Solved with, until the missing module is available: https://github.com/MichaIng/DietPi/commit/e41cd73

MichaIng commented 1 year ago

Better approach: https://github.com/MichaIng/DietPi/commit/3248247

MichaIng commented 1 year ago

Now solving this really.

MichaIng commented 1 year ago

Our new set of images has the needed kernel features now included, so that disabling cgroupv2 is not needed anymore: https://dietpi.com/downloads/images/testing/

The kernel itself can be upgraded as well with the matching firmware package from here: https://dietpi.com/downloads/binaries/

Will ship this upgrade with next DietPi update, after some more testing and probably little enhancements to the kernel config.