bad performance/OOM killer under memory pressure #1745
Labels
Component: Memory Management
kernel memory management
Type: Performance
Performance improvement or performance problem
Milestone
It seems having a small ARC often performs better then having a large ARC and requiring memory reclaim. It seems the spl slab reclaim is mainly freeing slabs that are immediately needed again, and the arc reclaim is ineffective because it just causes fragmentation in the slabs. Since indirect reclaim doesn't stop ARC growing, it seems there is continuing fight over memory.
In kernel 3.8, this shows as high loads for spl_kmem_cache and kswapd, and a drop in performance.
In kernel 3.11, the OOM killer gets quickly invoked in case of memory pressure. There are likely 2 reasons for this: 1 vmalloc performance has increased hugely, and so the arc can grow much faster (ARC growth was limited by vmalloc performance). 2. Changes in kswapd has made it less aggressive, and so memory is reclaimed slower.
It seems the reclaim logic needs to be improved to better work with kswapd and be more effective. I suspect ARC growth needs to stopped when multiple indirect reclaims are happening. (In 3.11 my dd gets killed by the OOM killer without a single direct reclaim happening)
The text was updated successfully, but these errors were encountered: