Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752956AbdLDVse (ORCPT ); Mon, 4 Dec 2017 16:48:34 -0500 Received: from mail-eopbgr30130.outbound.protection.outlook.com ([40.107.3.130]:15250 "EHLO EUR03-AM5-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752851AbdLDVsa (ORCPT ); Mon, 4 Dec 2017 16:48:30 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=ktkhai@virtuozzo.com; Subject: Re: [PATCH 0/5] blkcg: Limit maximum number of aio requests available for cgroup To: Jeff Moyer Cc: Benjamin LaHaise , axboe@kernel.dk, viro@zeniv.linux.org.uk, tj@kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-aio@kvack.org, oleg@redhat.com References: <151240305010.10164.15584502480037205018.stgit@localhost.localdomain> <20171204165213.GF11494@kvack.org> <08b9cab6-5237-c027-3bf3-08a69de7fe41@virtuozzo.com> From: Kirill Tkhai Message-ID: <4faaaeb9-a574-6443-4787-d42d724f0631@virtuozzo.com> Date: Tue, 5 Dec 2017 00:48:17 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [89.178.229.144] X-ClientProxiedBy: HE1PR0202CA0021.eurprd02.prod.outlook.com (2603:10a6:3:8c::31) To VI1PR0801MB1343.eurprd08.prod.outlook.com (2603:10a6:800:3b::7) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 86d7c74d-59be-478a-b956-08d53b60bcb9 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(5600026)(4604075)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(2017052603286);SRVR:VI1PR0801MB1343; X-Microsoft-Exchange-Diagnostics: 1;VI1PR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FdauumQRC6av7nn7BRvfEJ4z5DBaVUr+fy2zxq/1hMHY/NmDS/UFtf7eRpzJpjzfmx5HBiMR2C3UL+7v72SVdmFCzmUs6wj7uMJCtv5ACxlkm9T6d5mBjW8dmC5ECuVF6ti806wyZq7tuB94xZR8xCz8MW2gdoA4refiWYt/GDCI9a7qpeB6mMmK5468HMNa3O/Y/0nCPjlrVyeZD/SON7B5YQZ1HW5ITFAs5w4n/Am8GVsXfJwE5dWTzp/YnvyilHJSzJqgY=;4:ayNnkRPSdp+Zy+szj1/F1yhTiNAq7+YVW5meDjKv8tj3VY0PqoHSRxIR4KO5mhp1YNNfV14bF7jPD5bHDH82BO292N2g+DIOKaf+yKTO5CRo3KMaX0vQoOyQYOwLBV5BybDglhLaBRltj1FhsnGUK13usiO2IALsJXVme8d+/mvk5Fcd5RYv8XJOAQBPgCI9CITXX0RVFafEqp58goc5AzYkYjMVhMdPZoZ4LmUy1R+eTnTv6SDa4yV04HUDS7w6XPCS7qHGvm06sOT0UbtsIQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(8121501046)(5005006)(93006095)(93001095)(3231022)(3002001)(10201501046)(6041248)(20161123562025)(20161123560025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123555025)(20161123558100)(20161123564025)(6072148)(201708071742011);SRVR:VI1PR0801MB1343;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:VI1PR0801MB1343; X-Forefront-PRVS: 051158ECBB X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(6069001)(6009001)(346002)(366004)(376002)(199003)(24454002)(189002)(86362001)(97736004)(31696002)(64126003)(50466002)(105586002)(66066001)(106356001)(47776003)(65956001)(65806001)(33646002)(52146003)(23676004)(16526018)(58126008)(6486002)(6506006)(53546010)(6246003)(2906002)(76176011)(4326008)(54356011)(52116002)(2486003)(93886005)(316002)(7736002)(81156014)(6306002)(6512007)(236005)(189998001)(65826007)(2950100002)(53936002)(6916009)(230700001)(305945005)(8676002)(81166006)(5660300001)(3846002)(6116002)(478600001)(25786009)(8936002)(229853002)(83506002)(966005)(68736007)(31686004)(101416001)(36756003);DIR:OUT;SFP:1102;SCL:1;SRVR:VI1PR0801MB1343;H:localhost.localdomain;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtWSTFQUjA4MDFNQjEzNDM7MjM6MnAwRS8zV1J3UkhqRktxaUVQKzJTaEdB?= =?utf-8?B?RFpNWGlNUkZXcit0ZTdxZUxTWGVwYmtsaWVXSFIwcWZFa2cwK245UEpIZnBJ?= =?utf-8?B?M0xXZGdpcnYzR0gxYWhPOXMybFJwNGtmNFI3enBkT21oanZuSkEwdXJWRkJ3?= =?utf-8?B?ajM5TGtTNG1zZjZlNEsvSkpjcjRHdVJHcmVEMjlwQmIyeWxrVjlWUGRnS3NW?= =?utf-8?B?SDArR1VjczZiMGtxL3FNQTRHQWVUc2llc3RmQnpBZWtRYmZWcndxcEFtNzZr?= =?utf-8?B?T2RndWV2VnVzMjdzWFVIK3ZFTk85blBiZmk3bS9nZ3hxYXYxbVBZVGpVeHY4?= =?utf-8?B?UnpqS0R4V2Y3SXl2RlRMUnBxRHBvbEszODdWSnk1c25iZXY4UnVRNVcvVDZC?= =?utf-8?B?WFROdTl6U2o1NFJMQk1USEVLNlBlekJhQlBjUjRNSktDUlFSeXpaU09BT3pJ?= =?utf-8?B?Z0g4bC82dXJqOXlBeEhlcWhic1NjNzI1b3JRRGE1ejRJRjd2ZWs2bkRJMFNP?= =?utf-8?B?c0VPb2gyd0xTREhoM1FrcnRjTzVQaC9PZ2VER1NrcmFEKzZwMXNaK1RGMFNS?= =?utf-8?B?SjB5aStYMWNYUnh4a1l0ZFdOZFpVbGpKc05nQkZ6cDRZY3pNQk1KYkZqbW93?= =?utf-8?B?dVdYNjlZVzJXe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V/2D6DtKAnBe7a+OcYPN42aX1nLqjYTY+4rhoG4jfl89jkSLhFZp10e/FXGSdaOM=;7:2YweLf/22/pi4gzA6Yzxxwlpa1O+5NFBFe5QRVm9lxZ1ANao4Z/orCokvQvT3nJ4Y1QjfHUdvT1HN6jpNOxaqZ2mvyi1Bm7c5fHMG2QLuX/dLGlGrUwlkyhEh1HhfAc8hGOfE4ZDXtRabDTU0tzm2vqWTwduqZtpgDZ57cvRlnZC4id3iFH7wKsiI2TV6gzGNyKp2zauY/S9sxqUnIccGBRhnLv4MjObxgyxOx3TGnrQk+/oGm3oi51egLbQoRtp SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;VI1PR0801MB1343;20:83tzLsQThFknNon9gbebPt6wDksxktzJ1Bsm4iVvNWwXx16g70Pdx5jpHweYcr7O49oAKRM+q8SUrfp5NEL9/V0gAhTTslXnwnj3nS5wioNZalx8WRe/01PQlYpNifuKTKTrk4qWaMAQ5xC8p7BJ48xpQVOqT3JwAUNFQZt27Jo= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Dec 2017 21:48:19.7292 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 86d7c74d-59be-478a-b956-08d53b60bcb9 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0801MB1343 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2399 Lines: 70 On 05.12.2017 00:35, Jeff Moyer wrote: > Kirill Tkhai writes: > >> Hi, Benjamin, >> >> On 04.12.2017 19:52, Benjamin LaHaise wrote: >>> Hi Kirill, >>> >>> On Mon, Dec 04, 2017 at 07:12:51PM +0300, Kirill Tkhai wrote: >>>> Hi, >>>> >>>> this patch set introduces accounting aio_nr and aio_max_nr per blkio cgroup. >>>> It may be used to limit number of aio requests, which are available for >>>> a cgroup, and could be useful for containers. >>>> >>>> The accounting is hierarchical, and aio contexts, allocated in child cgroup, >>>> are accounted in parent cgroups too. >>>> >>>> Also, new cgroup file "io.aio_nr" is introduced. It's used to set cgroup >>>> aio requests limit, to show current limit and number of currenly occupied >>>> requests. >>> >>> Where are your test cases to check this functionality in the libaio test >>> suite? >> >> I tried to find actual libaio test suite repository url in google, >> but there is no certain answer. Also, there is no information in kernel >> anywhere (I hope I grepped right). >> >> Could you please provide url where actual upstream libaio could be obtained? > > https://pagure.io/libaio > > Patches can be sent to this list (linux-aio). > Thank you, Jeff. Kirill >>>> Patches 1-3 are refactoring. >>>> Patch 4 is the place where the accounting actually introduced. >>>> Patch 5 adds "io.aio_nr" file. >>>> >>>> --- >>>> >>>> Kirill Tkhai (5): >>>> aio: Move aio_nr increment to separate function >>>> aio: Export aio_nr_lock and aio_max_nr initial value to include/linux/aio.h >>>> blkcg: Add blkcg::blkg_aio_nr and blkcg::blkg_aio_max_nr >>>> blkcg: Charge aio requests in blkio cgroup hierarchy >>>> blkcg: Add cgroup file to configure blkcg::blkg_aio_max_nr >>>> >>>> >>>> block/blk-cgroup.c | 88 +++++++++++++++++++++++++- >>>> fs/aio.c | 151 ++++++++++++++++++++++++++++++++++++++++---- >>>> include/linux/aio.h | 21 ++++++ >>>> include/linux/blk-cgroup.h | 4 + >>>> 4 files changed, 247 insertions(+), 17 deletions(-) >>>> >>>> -- >>>> Signed-off-by: Kirill Tkhai >>>> >>> >> >> -- >> To unsubscribe, send a message with 'unsubscribe linux-aio' in >> the body to majordomo@kvack.org. For more info on Linux AIO, >> see: http://www.kvack.org/aio/ >> Don't email: aart@kvack.org