[LTP] [PATCH v1] mmapstress06: Rate limit page-dirtying loop to prevent MemCG OOM-kills

Andrea Cervesato andrea.cervesato@suse.com
Thu Aug 27 10:06:31 CEST 2026


> I guess "need to do things by hand" includes totally removing the hard
> sleep time; currently, I have no good solution (as I mentioned in previous
> comments, memory.reclaim is not an option).

yes, basically we re-implement some sort of OOM-killer/memory.reclaim
inside the code, instead of using them directly. That means we need to
disable OOM killer, loop over the current swap status and eventually
raise an error if after N iterations pages are not swapped.

But I feel it's not deterministic because on a really slow device we
might run out of iterations. I still think memory.reclaim is the best
choice for v2 in this case, because it will wait until a certain amount
of memory has been reclaimed and eventually raise an error.

@Cyril do you have any idea on how to proceed here?	

--
Andrea Cervesato
SUSE QE Automation Engineer Linux
andrea.cervesato@suse.com


More information about the ltp mailing list