From aacf6f622df16aa1fabaadfea1ef6f64a004154d Mon Sep 17 00:00:00 2001 From: Felix Obenhuber Date: Thu, 21 Sep 2023 09:52:05 +0200 Subject: [PATCH] Add oom_group_kill cgroup event type --- northstar-runtime/src/runtime/cgroups.rs | 1 + northstar-runtime/src/runtime/events.rs | 3 +++ 2 files changed, 4 insertions(+) diff --git a/northstar-runtime/src/runtime/cgroups.rs b/northstar-runtime/src/runtime/cgroups.rs index 448ae10fe..7c8cf3539 100644 --- a/northstar-runtime/src/runtime/cgroups.rs +++ b/northstar-runtime/src/runtime/cgroups.rs @@ -377,6 +377,7 @@ fn parse_cgroups_event(s: &str) -> CGroupEvent { Some("max") => event.max = value, Some("oom") => event.oom = value, Some("oom_kill") => event.oom_kill = value, + Some("oom_group_kill") => event.oom_group_kill = value, Some(_) | None => panic!("invalid content of memory.events"), } } diff --git a/northstar-runtime/src/runtime/events.rs b/northstar-runtime/src/runtime/events.rs index c6344f42b..efc6ee218 100644 --- a/northstar-runtime/src/runtime/events.rs +++ b/northstar-runtime/src/runtime/events.rs @@ -66,4 +66,7 @@ pub(crate) struct MemoryEvent { /// The number of processes belonging to this cgroup /// killed by any kind of OOM killer. pub oom_kill: Option, + /// The number of times the entire cgroup has been kill + /// by any kind of OOM killler. + pub oom_group_kill: Option, }