balena-os / balenaos-in-container

Run balenaOS as a docker container
https://www.balena.io/os/
Apache License 2.0
49 stars 14 forks source link

host system max_user_namespaces is set to 0 #53

Open klutchell opened 2 years ago

klutchell commented 2 years ago

When running this container on Ubuntu derivatives and using cgroups v1 as required, the host max_user_namespaces can get reset to 0 causing various issues on the host.

Linux system76 5.15.11-76051511-generic #202112220937~1640185481~21.04~b3a2c21-Ubuntu SMP Mon Jan 3 16:5 x86_64 x86_64 x86_64 GNU/Linux

Retrieve the current value with

sudo sysctl -a | grep max_user_namespaces

Can be restored with

echo 10000 | sudo tee /proc/sys/user/max_user_namespaces