Hello. On Tue, Dec 24, 2024 at 02:52:38AM +0000, Chen Ridong <chenridong@xxxxxxxxxxxxxxx> wrote: > A soft lockup issue was found in the product with about 56,000 tasks were > in the OOM cgroup, it was traversing them when the soft lockup was > triggered. Why is this softlockup a problem? It's lot of tasks afterall and possibly a slow console (given looking for a victim among the comparable number didn't trigger it). > To fix this issue, call 'cond_resched' in the 'mem_cgroup_scan_tasks' > function per 1000 iterations. For global OOM, call > 'touch_softlockup_watchdog' per 1000 iterations to avoid this issue. This only hides the issue. It could be similarly fixed by simply decreasing loglevel= ;-) cond_resched() in the memcg case may be OK but the arbitrary touch for global situation may hide possibly useful troubleshooting information. (Yeah, cond_resched() won't fit inside RCU section as in other global task iterations.) 0.02€, Michal
Attachment:
signature.asc
Description: PGP signature