You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Changes in cgroupv2 cause coder stat to fail for CPU and memory
$ coder stat mem
Encountered an error running "coder stat mem", see "coder stat mem --help" for more information
error: read memory total: read /sys/fs/cgroup/memory/memory.limit_in_bytes: open /sys/fs/cgroup/memory/memory.limit_in_bytes: no such file or directory
This happens when cgroupv2 is active, and you're inside a container.
The default location of these for cgroupv2 has changed to, i.e.: /sys/fs/cgroup/memory.max BUT this is only true of a 'native' execution, i.e. a VM/host/node. When you run inside a container (read as a pod in k8s) the files will be split up, i.e. /sys/fs/cgroup/system.slice/memory.max or address with some 'obscure' identifiers.
The current agents are therefore likely to show up as failing due to not finding the right resource.