Enabling Cgroup v2 on RHEL 9 / Rocky Linux 9 (Versions 9.2 to 9.6+)

Steps to re-enable cgroup v2 on RHEL 9 and Rocky Linux 9 if the system was previously switched to cgroup v1.

Default Status: Cgroup v2 is the native default unified hierarchy on RHEL 9 and Rocky Linux 9.

Follow the steps below only if cgroup v1 was previously enabled on your system.

  1. Update the kernel arguments using grubby to re-enable the unified cgroup hierarchy:
    sudo grubby --update-kernel=ALL --args="systemd.unified_cgroup_hierarchy=1"
  2. Reboot the system:
    sudo reboot
  3. After the system restarts, verify that cgroup v2 is active by running:
    stat -fc %T /sys/fs/cgroup/
    The output should display cgroup2fs, confirming that cgroup v2 is active.