Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758193AbcLAShN (ORCPT ); Thu, 1 Dec 2016 13:37:13 -0500 Received: from mail-io0-f194.google.com ([209.85.223.194]:34593 "EHLO mail-io0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757869AbcLAShL (ORCPT ); Thu, 1 Dec 2016 13:37:11 -0500 MIME-Version: 1.0 In-Reply-To: References: <20161128072315.GC14788@dhcp22.suse.cz> <20161129155537.f6qgnfmnoljwnx6j@merlins.org> <20161129160751.GC9796@dhcp22.suse.cz> <20161129163406.treuewaqgt4fy4kh@merlins.org> <20161129174019.fywddwo5h4pyix7r@merlins.org> <20161130174713.lhvqgophhiupzwrm@merlins.org> <20161130203011.GB15989@htj.duckdns.org> <20161201135014.jrr65ptxczplmdkn@kmo-pixel> From: Linus Torvalds Date: Thu, 1 Dec 2016 10:37:09 -0800 X-Google-Sender-Auth: 0zzH3KpCFpd2CHJzVCeUv8zH-sQ Message-ID: Subject: Re: 4.8.8 kernel trigger OOM killer repeatedly when I have lots of RAM that should be free To: Jens Axboe Cc: Kent Overstreet , Tejun Heo , Marc MERLIN , Michal Hocko , Vlastimil Babka , linux-mm , LKML , Joonsoo Kim , Greg Kroah-Hartman Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1037 Lines: 22 On Thu, Dec 1, 2016 at 10:30 AM, Jens Axboe wrote: > > It's two different kinds of throttling. The vm absolutely should > throttle at dirty time, to avoid having insane amounts of memory dirty. > On the block layer side, throttling is about avoid the device queues > being too long. It's very similar to the buffer bloating on the > networking side. The block layer throttling is not a fix for the vm > allowing too much memory to be dirty and causing issues, it's about > keeping the device response latencies in check. Sure. But if we really do just end up blocking in the block layer (in situations where we didn't used to), that may be a bad thing. It might be better to feed that information back to the VM instead, particularly for writes, where the VM layer already tries to ratelimit the writes. And frankly, it's almost purely writes that matter. There just aren't a lot of ways to get that many parallel reads in real life. I haven't looked at your patches, so maybe you already do this. Linus