Re: [RFC] [PATCH] Cgroup based OOM killer controller

From: David Rientjes
Date: Thu Jan 22 2009 - 05:21:20 EST


On Thu, 22 Jan 2009, Nikanth Karthikesan wrote:

> I think cpusets preference could be improved, not to depend on badness, with
> something similar to what memcg does. With or without adding overhead of
> tracking processes that has memory from a node.
>

We actually used to do that: we excluded all tasks that did not share the
same cpuset in select_bad_process(). That exclusion was reimplemented as
a preference in badness() since, again, it is quite possible that a large
memory-hogging task without a sufficient oom_adj score, as you mentioned,
has allocated memory on the cpuset's nodes before being moved to a
different cpuset or changing its set of allowable nodes.

I think you would find the per-cgroup oom notifier patch[*] of interest.
It seems to have been dropped after some discussion on improvements, but
allows you to defer all of these decisions to userspace. Would something
like that fix your problem?

[*] http://marc.info/?l=linux-mm&m=122575082227252
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/