Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: David Rientjes
Date: Tuesday, November 9, 2010 - 2:25 pm

On Tue, 9 Nov 2010, David Rientjes wrote:


Yes, CAP_SYS_RESOURCE was a part of the heuristic in 2.6.25 along with 
CAP_SYS_ADMIN and was removed with the rewrite; when I said it "hasn't had 
a place in the oom killer's heuristic," I meant it's an unnecessary 
extention to CAP_SYS_ADMIN and allows for killing innocent tasks when a 
CAP_SYS_RESOURCE task is using too much memory.

The fundamental issue here is whether or not we should give a bonus to 
CAP_SYS_RESOURCE tasks because they are, by definition, allowed to access 
extra resources and we're willing to sacrifice other tasks for that.  This 
is antagonist to the oom killer's sole goal, however, which is to kill the 
task consuming the largest amount of memory unless protected by userspace 
(which CAP_SYS_RESOURCE has completely control in doing).

Since these threads have complete ability to give themselves this bonus 
(echo -30 > /proc/self/oom_score_adj), I don't think this needs to be a 
part of the core heuristic nor with such an arbitrary value of 3% (the old 
heuristic divided its badness score by 4, another arbitrary value).
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, David Rientjes, (Wed Nov 3, 4:47 pm)
Re:[PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, David Rientjes, (Wed Nov 3, 6:50 pm)
Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, KOSAKI Motohiro, (Tue Nov 9, 4:01 am)
Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, David Rientjes, (Tue Nov 9, 2:06 pm)
Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, David Rientjes, (Tue Nov 9, 2:25 pm)
Re: [PATCH v2]oom-kill: CAP_SYS_RESOURCE should get bonus, David Rientjes, (Wed Nov 10, 1:50 pm)
Re: [PATCH] Revert oom rewrite series, Figo.zhang, (Sun Nov 14, 8:26 pm)
Re: [PATCH] Revert oom rewrite series, David Rientjes, (Mon Nov 15, 3:14 am)
Re: [PATCH] Revert oom rewrite series, Alan Cox, (Mon Nov 15, 3:57 am)
Re: [PATCH] Revert oom rewrite series, David Rientjes, (Mon Nov 15, 1:54 pm)
Re: [PATCH] Revert oom rewrite series, KOSAKI Motohiro, (Tue Nov 23, 12:16 am)