Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6689652imu; Mon, 21 Jan 2019 13:48:37 -0800 (PST) X-Google-Smtp-Source: ALg8bN5fyC6O5RcKQnoNyKKQbQRp+Wp3UipE5cqUrPeSfekcdwENmQQGzyTIeI2zJxjY0Ypa95eL X-Received: by 2002:a17:902:7296:: with SMTP id d22mr32306356pll.265.1548107317049; Mon, 21 Jan 2019 13:48:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548107317; cv=none; d=google.com; s=arc-20160816; b=Id6EKucIDujI2W9txalSLQPNZQMCAApbf1iimdZxvMifMwzkeSJDAiJngtPesGwCNe m/hNyqJbUKGTCztyL6Ev4jjyEjrfLFQ2tShjvkA/F+jPlBJy5ddfoMtMrNswytvpzkeT k07HpzdFOKKpqMXDy4HK9ZUP2F556cL9Fbi+M6n31e9YwjZc1zoWmHEWRHQjNfhsbKyf QfCCBjTk+fKa9D2dqQuPUAaq9gyufejuZpZ91W5Go+gl61oFLrInusunmnwWszEE7/wX zq7LnIgXknDDe0VvrXtJY31oOo/3IHVn0vgjCSY6iOvY2s4tut+Vrg6nnCWHl44zMZ3u q0bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=sOdgrKMGfyQOdAVAj+YJxiYVU+fAbQEsqmCHAfG4y0Y=; b=ePcIDXKAqDrE3eCRsg/B2vQvonqxnQa/XT2KLMbeo58B1aqi/v9q7StdsoYI4J7sO0 ZX5uJdTT6GoRYP6yRMlrW0DX5OyYPVSh7abn85wO2pJLzxlsKxtPcBRT/nvbEQd9w23p 6zbvm5YEqMHL9+WauC2bHovPb5ALMF/lfvVEjq1ocmorkXm1bI3M6dqrQ9uYPidOYxwv OL9NqDBp0d1tkC25QBSipfq/sNKJz/5Isstsy6wAPHmBgNQk/JgOPpeIO+9Ed+FNp3VK 1Pa0JDjyw2iQrX70LaF4Ws7JuiNueARJC0PMQ5rw0G1PKiUKI6HJrXkkTIlUd2B4D0MV bs8Q== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u11si12576518plq.287.2019.01.21.13.48.21; Mon, 21 Jan 2019 13:48:37 -0800 (PST) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727012AbfAUVrQ (ORCPT + 99 others); Mon, 21 Jan 2019 16:47:16 -0500 Received: from mx1.redhat.com ([209.132.183.28]:46612 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726004AbfAUVrQ (ORCPT ); Mon, 21 Jan 2019 16:47:16 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3C2F97F6CB; Mon, 21 Jan 2019 21:47:16 +0000 (UTC) Received: from horse.redhat.com (unknown [10.18.25.156]) by smtp.corp.redhat.com (Postfix) with ESMTP id 118C1648AF; Mon, 21 Jan 2019 21:47:15 +0000 (UTC) Received: by horse.redhat.com (Postfix, from userid 10451) id 7771922024A; Mon, 21 Jan 2019 16:47:15 -0500 (EST) Date: Mon, 21 Jan 2019 16:47:15 -0500 From: Vivek Goyal To: Andrea Righi Cc: Josef Bacik , Tejun Heo , Li Zefan , Johannes Weiner , Jens Axboe , Dennis Zhou , cgroups@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH 0/3] cgroup: fsio throttle controller Message-ID: <20190121214715.GA27713@redhat.com> References: <20190118103127.325-1-righi.andrea@gmail.com> <20190118163530.w5wpzpjkcnkektsp@macbook-pro-91.dhcp.thefacebook.com> <20190118184403.GB1535@xps-13> <20190118194652.gg5j2yz3h2llecpj@macbook-pro-91.dhcp.thefacebook.com> <20190119100827.GA1630@xps-13> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20190119100827.GA1630@xps-13> User-Agent: Mutt/1.10.1 (2018-07-13) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Mon, 21 Jan 2019 21:47:16 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jan 19, 2019 at 11:08:27AM +0100, Andrea Righi wrote: [..] > Alright, let's skip the root cgroup for now. I think the point here is > if we want to provide sync() isolation among cgroups or not. > > According to the manpage: > > sync() causes all pending modifications to filesystem metadata and cached file data to be > written to the underlying filesystems. > > And: > According to the standard specification (e.g., POSIX.1-2001), sync() schedules the writes, but > may return before the actual writing is done. However Linux waits for I/O completions, and > thus sync() or syncfs() provide the same guarantees as fsync called on every file in the sys‐ > tem or filesystem respectively. > > Excluding the root cgroup, do you think a sync() issued inside a > specific cgroup should wait for I/O completions only for the writes that > have been generated by that cgroup? Can we account I/O towards the cgroup which issued "sync" only if write rate of sync cgroup is higher than cgroup to which page belongs to. Will that solve problem, assuming its doable? Vivek