I have an old script that do
$(cat /sys/fs/cgroup/memory/memory.limit_in_bytes)
In fedora 33 this file is not present.
What can I do to resolve this?
Thanks.
I have an old script that do
$(cat /sys/fs/cgroup/memory/memory.limit_in_bytes)
In fedora 33 this file is not present.
What can I do to resolve this?
Thanks.
The issue is related to new cgroup v2. To resolve this, revert cgroup to v1:
sudo sed -i '/^GRUB_CMDLINE_LINUX/ s/"$/ systemd.unified_cgroup_hierarchy=0"/' /etc/default/grub
and reboot.
After this /sys/fs/cgroup/memory/memory.limit_in_bytes will be present.
Before rebooting, it's necessary to redo the command to regenerate grub. For Fedora 33, the commands are:
grub2-mkconfig -o /boot/grub2/grub.cfg
grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg