On 9/19/19 12:21 PM, Stefan Priebe - Profihost AG wrote: > Kernel 5.2.14 is now running since exactly 7 days and now we can easaly > view a trend i', not sure if i should post graphs. > > Cache size is continuously shrinking while memfree is rising. > > While there were 4,5GB free in avg in the beginnen we now have an avg of > 8GB free memory. > > Cache has shrinked from avg 24G to avg 18G. > > Memory pressure has rised from avg 0% to avg 0.1% - not much but if you > look at the graphs it's continuously rising while cache is shrinking and > memfree is rising. Hi, could you try the patch below? I suspect you're hitting a corner case where compaction_suitable() returns COMPACT_SKIPPED for the ZONE_DMA, triggering reclaim even if other zones have plenty of free memory. And should_continue_reclaim() then returns true until twice the requested page size is reclaimed (compact_gap()). That means 4MB reclaimed for each THP allocation attempt, which roughly matches the trace data you preovided previously. The amplification to 4MB should be removed in patches merged for 5.4, so it would be only 32 pages reclaimed per THP allocation. The patch below tries to remove this corner case completely, and it should be more visible on your 5.2.x, so please apply it there.