GitHub PushEvent at 2014-05-11 18:19:03
Repository: Blaze.Kernel-S5
Actor: GuneetAtwal
Payload: {"shas":[["6b70c7da235a6d284aa9f7dfb68c54018ac13cb3","d8cd2994e15bc61ddb2b113030bda55eebc3a0fe@google.com","mm, oom: base root bonus on current usage\n\nA 3% of system memory bonus is sometimes too excessive in comparison to\nother processes.\n\nWith commit a63d83f427fb (\"oom: badness heuristic rewrite\"), the OOM\nkiller tries to avoid killing privileged tasks by subtracting 3% of\noverall memory (system or cgroup) from their per-task consumption.  But\nas a result, all root tasks that consume less than 3% of overall memory\nare considered equal, and so it only takes 33+ privileged tasks pushing\nthe system out of memory for the OOM killer to do something stupid and\nkill dhclient or other root-owned processes.  For example, on a 32G\nmachine it can't tell the difference between the 1M agetty and the 10G\nfork bomb member.\n\nThe changelog describes this 3% boost as the equivalent to the global\novercommit limit being 3% higher for privileged tasks, but this is not\nthe same as discounting 3% of overall memory from _every privileged task\nindividually_ during OOM selection.\n\nReplace the 3% of system memory bonus with a 3% of current memory usage\nbonus.\n\nBy giving root tasks a bonus that is proportional to their actual size,\nthey remain comparable even when relatively small.  In the example\nabove, the OOM killer will discount the 1M agetty's 256 badness points\ndown to 179, and the 10G fork bomb's 262144 points down to 183500 points\nand make the right choice, instead of discounting both to 0 and killing\nagetty because it's first in the task list.\n\nSigned-off-by: David Rientjes <rientjes@google.com>\nReported-by: Johannes Weiner <hannes@cmpxchg.org>\nAcked-by: Johannes Weiner <hannes@cmpxchg.org>\nCc: Michal Hocko <mhocko@suse.cz>\nCc: <stable@vger.kernel.org>\nSigned-off-by: Andrew Morton <akpm@linux-foundation.org>\nSigned-off-by: Linus Torvalds <torvalds@linux-foundation.org>","David Rientjes",true]],"size":1,"ref":"refs/heads/4.4_tw_mr1","head":"6b70c7da235a6d284aa9f7dfb68c54018ac13cb3"}