Received: by 2002:a25:b794:0:0:0:0:0 with SMTP id n20csp4607917ybh; Tue, 6 Aug 2019 14:47:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqxzHmgKsXi/po7jJKlJL3b4XoOgCSIu8+jUP69kAGOqUO062GAWn2NJBYYpgL024QJiNOsi X-Received: by 2002:a17:902:7083:: with SMTP id z3mr122456plk.87.1565128033454; Tue, 06 Aug 2019 14:47:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565128033; cv=none; d=google.com; s=arc-20160816; b=MFZmKG8H7BqxliOqmt3GyM3MUtevcN/K5/LZWLirXm6ukcG3DWgTqsRRGRzCgnFrdq xvzKH+fDcSsEmnqL9isFV6IN39VSrsMsF2eMV4dccajqLJpH44Onl0Y9QUJAlmrqv707 LJ6TSmg+8jUAPc6/2wWsIM36O2eyPf6aNNKV57Baok1LZDabZA+7i0F2Pt53j8bxTL/t PSRbHJP4CQXx7D4+7N4thQPocMeCR4Xd+fLvOym9nWyxBY343/DkGagZvb7oO1H9vl9V plM0ENmrBKxd2xoCZwJasgkGo2yhFURSwT+u/88HaEOxHYZy1XL7zQGGyfMdAsKp6H3M 6iDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Xj5yWDm+drkTcWobF+B+SfSeu4cUAiftcsjQzbtvZZY=; b=NFExst261kDVB4HGav9NxSqNHgee/tEtSuCMEbEsofrzxpvr8AOCcQj5TQ2ZDwCgbc 2MM0aohnB6NhPkGSMIvw4EQjc56SI+oYKXcgtr1VSgh2KZdovOyAcXb18hm+qCPnEFzD p00N0gd4OoqUT3CScyhIrQ4a9EmFf5ZA3W3b5TRptkUrTQx4pdNSqYmA9NxM5H1hP1q/ BCkYfufrY9e6kConG11g4q84R9arbRG11JnTHqhFb1Lvl3xdU04JWI8Ykdcl0C0Ayp9o yZyc7we7dHOQONW3nZKDCGgHa4NP0Ha0/c21XD8GYav9XL3W6lkNzrVCceLGoKryBuD8 7hiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Nlp8ZXU+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o75si15900835pje.87.2019.08.06.14.46.58; Tue, 06 Aug 2019 14:47:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Nlp8ZXU+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728522AbfHFVoF (ORCPT + 99 others); Tue, 6 Aug 2019 17:44:05 -0400 Received: from mail-yw1-f65.google.com ([209.85.161.65]:34519 "EHLO mail-yw1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726375AbfHFVoD (ORCPT ); Tue, 6 Aug 2019 17:44:03 -0400 Received: by mail-yw1-f65.google.com with SMTP id q128so31392324ywc.1 for ; Tue, 06 Aug 2019 14:44:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Xj5yWDm+drkTcWobF+B+SfSeu4cUAiftcsjQzbtvZZY=; b=Nlp8ZXU+iRYXz+eicM7sucfWByTxLZlSUEMe+5TCM0kxhttbD8YZQUoFTWZunYxXmp I/e5wOSzrUceMTBbGN1OQmuTBK1yQQWZYghpIASRwkYcOdsdzIT9crfPdYhBnUOREvPd jbHe+qXPQnE98IT0H4cclpWE0x1lzeLnHP/d53ETi4wtdMc6UD+cr0bMoVgG5ZnL6ynp Fij+6I0DxihfeV8S+h3SanKCuoWcbO8PLk5idomALLwVkakjOytRnXyvWQg8K/XIM3Ch P5Z7BOxrkVbdR9/hmjTFkfKlXcpwDTHqy8XIvJnUEflwRu/ysG1KZ4aGfqrBSjTy5JBh 5vqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Xj5yWDm+drkTcWobF+B+SfSeu4cUAiftcsjQzbtvZZY=; b=b3HcNW0cTr+OnJpTcV4iBDTuMBXPXkInN9Y7FXpHJPjmo+XQzXU0kzuNb7qoAVMYxa RrH/AMx0mimAEiQH+z6mHLQCFoFUxv2Ami91of5W/2uKA7aqZ9GLvos3XhB+Ktb0UuOg 1tm1jZnMLFIqkszU0E6qAv8eipxhw5aNyjz9iSiZedncxgtjNDqxkrMeK40KtoZk7qLX UNHwa1x/bX1L/WnK9cFMAKTTiKhWGnAiJl420W1hGWeww5094ItmVB6cXPSN0C1aTXJN 73krDnw+Xb0zF9GkBxOJFNjrendCnThrhRZv/lROtnWjKYiSAjmhLDS2NPkzng1IHSgW NKIg== X-Gm-Message-State: APjAAAX1lfDAiRLX1r9aS6RgObM0L9emCi4SX6psVJM5LLMoWqFp3bNu yVo+oI2bi/BoJ6fIzZwenrEBkmBILpi+rXB9Plk= X-Received: by 2002:a81:5c0a:: with SMTP id q10mr3990074ywb.474.1565127842511; Tue, 06 Aug 2019 14:44:02 -0700 (PDT) MIME-Version: 1.0 References: <20190805193148.GB4128@cmpxchg.org> In-Reply-To: From: James Courtier-Dutton Date: Tue, 6 Aug 2019 22:43:25 +0100 Message-ID: Subject: Re: Let's talk about the elephant in the room - the Linux kernel's inability to gracefully handle low memory pressure To: Suren Baghdasaryan Cc: Johannes Weiner , Vlastimil Babka , "Artem S. Tashkinov" , LKML , linux-mm , Michal Hocko Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 6 Aug 2019 at 02:09, Suren Baghdasaryan wrote: > > 80% of the last 10 seconds spent in full stall would definitely be a > problem. If the system was already low on memory (which it probably > is, or we would not be reclaiming so hard and registering such a big > stall) then oom-killer would probably kill something before 8 seconds > are passed. There are other things to consider also. I can reproduce these types of symptoms and memory pressure is 100% NOT the cause. (top showing 4GB of a 16GB system in use) The cause as I see it is disk pressure and the lack of multiple queues for disk IO requests. For example, one process can hog 100% of the disk, without other applications even being able to write just one sector. We need a way for the linux kernel to better multiplex access to the disk. Adding QOS, allowing interactive processes to interrupt long background disk IO tasks. If we could balance disk access across each active process, the user, on their desktop, would think the system was more responsive. Kind Regards James