Re: [patch] swapin rlimit

Rob Landley
2005-11-04T15:14:01Z

On Friday 04 November 2005 01:36, Andrew Morton wrote:
> > wouldnt the clean solution here be a "swap ulimit"?
>
> Well it's _a_ solution, but it's terribly specific.
>
> How hard is it to read /proc/<pid>/nr_swapped_in_pages and if that's
> non-zero, kill <pid>?

Things like make fork lots of short-lived child processes, and some of those
can be quite memory intensive. (The gcc 4.0.2 build causes an outright swap
storm for me about halfway through, doing genattrtab and then again compiling
the result).

Is there any way for parents to collect their child process's statistics when
the children exit? Or by the time the actual swapper exits, do we not care
anymore?

Rob