答复: [PATCH] mm: limit a process RSS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----邮件原件-----
> 发件人: Michal Hocko [mailto:mhocko@xxxxxxxxxx]
> 发送时间: 2018年4月3日 15:37
> 收件人: Li,Rongqing <lirongqing@xxxxxxxxx>
> 抄送: akpm@xxxxxxxxxxxxxxxxxxxx; kirill.shutemov@xxxxxxxxxxxxxxx;
> jglisse@xxxxxxxxxx; minchan@xxxxxxxxxx; linux-mm@xxxxxxxxx
> 主题: Re: [PATCH] mm: limit a process RSS
> 
> On Mon 02-04-18 15:45:19, Li RongQing wrote:
> > we cannot limit a process RSS although there is ulimit -m, not sure
> > why and when ulimit -m is not working, make it work
> 
> Could you be more specific about why do you need this functionality?
> The RSS limit has never been implemented AFAIK and the main reason is that
> the semantic is quite weak to be useful (e.g. the shared memory accounting,
> resident memory that is not mapped etc.).

avoid some buggy process will exhaust memory, sometime the engineer did not sure if an application has bug since lots of conditions are needed to trigger bug, like an application will take more and more memory when lots of request arrived.

This method give user an alternative

> 
> We have memory cgroup controller as an alternative.

Memory cgroup is to control a group processes, But this method only control a process, if every process has a different limit, lots of cgroup need to create, if lots of cgroup, I think the cgroup maybe not efficient. 

This method did not count pagecache, and this method takes less cpu.

-RongQing
> --
> Michal Hocko
> SUSE Labs




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux