cgroups-rs icon indicating copy to clipboard operation
cgroups-rs copied to clipboard

notify_on_oom_v2 is being used in cgroup v2

Open Eason0729 opened this issue 1 year ago • 0 comments

Describe the bug memory.oom_control is used in notify_on_oom_v2, if I recall correctly, memory.oom_control only exist in cgroup v1 when memory subsystem is mounted.

Expected behavior Return ErrorKind::Other, or document the behavior somewhere.

Additional context

called `Result::unwrap()` on an `Err` value: Error { kind: ReadFailed("/sys/fs/cgroup/abc.0/memory.oom_control"), cause: Some(Os { code: 2, kind: NotFound, message: "No such file or directory" }) }

Eason0729 avatar May 16 '24 16:05 Eason0729