lkml.org 
[lkml]   [2012]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [patch 2/8] mm: vmscan: disregard swappiness shortly before going OOM
Date
On 12/14/2012 03:37 AM, Michal Hocko wrote:
> On Thu 13-12-12 23:50:30, Johannes Weiner wrote:
>> On Thu, Dec 13, 2012 at 10:25:43PM +0000, Satoru Moriya wrote:
>>>
>>> I introduced swappiness check here with fe35004f because, in some
>>> cases, we prefer OOM to swap out pages to detect problems as soon as
>>> possible. Basically, we design the system not to swap out and so if
>>> it causes swapping, something goes wrong.
>>
>> I might be missing something terribly obvious, but... why do you add
>> swap space to the system in the first place? Or in case of cgroups,
>> why not set the memsw limit equal to the memory limit?
>
> I can answer the later. Because memsw comes with its price and
> swappiness is much cheaper. On the other hand it makes sense that
> swappiness==0 doesn't swap at all. Or do you think we should get back
> to _almost_ doesn't swap at all?
>

Right. One of the reason is what Michal described above and another
reason that I thought is softlimit. softlimit reclaim always works
with priority=0. Therefore, if we set softlimit to one memcg without
swappiness=0, the kernel scans both anonymous and filebacked pages
during soft limit reclaim for the memcg and reclaims them.

Regards,
Satoru


\
 
 \ /
  Last update: 2012-12-14 21:21    [W:0.360 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site