Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933079AbcDYQme (ORCPT ); Mon, 25 Apr 2016 12:42:34 -0400 Received: from zimbra13.linbit.com ([212.69.166.240]:46245 "EHLO zimbra13.linbit.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752389AbcDYQmd (ORCPT ); Mon, 25 Apr 2016 12:42:33 -0400 From: Philipp Reisner To: Bart Van Assche Cc: Jens Axboe , "linux-kernel@vger.kernel.org" , "drbd-dev@lists.linbit.com" Subject: Re: [Drbd-dev] [PATCH 05/30] drbd: Introduce new disk config option rs-discard-granularity Date: Mon, 25 Apr 2016 11:21:17 -0500 Message-ID: <2101862.7IMGIqiMZK@phil-dell-xps.local> User-Agent: KMail/4.13.3 (Linux/3.13.0-55-generic; KDE/4.13.3; x86_64; ; ) In-Reply-To: <571E393E.1010003@sandisk.com> References: <1461586077-11581-1-git-send-email-philipp.reisner@linbit.com> <1461586077-11581-6-git-send-email-philipp.reisner@linbit.com> <571E393E.1010003@sandisk.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 957 Lines: 28 Am Montag, 25. April 2016, 08:35:26 schrieb Bart Van Assche: > On 04/25/2016 05:10 AM, Philipp Reisner wrote: > > As long as the value is 0 the feature is disabled. With setting > > it to a positive value, DRBD limits and aligns its resync requests > > to the rs-discard-granularity setting. If the sync source detects > > all zeros in such a block, the resync target discards the range > > on disk. > > Hello Phil, > > Can you explain why rs-discard-granularity is configurable instead of > e.g. setting it to the least common multiple of the discard > granularities of the underlying block devices at both sides? > > Thanks, > Hi Bart, we had this idea as well. It seems that real world devices like larger discards better than smaller discards. The other motivation was that a device mapper logical volume might change it on the fly... So we think it is best to delegate the decision on the discard chunk size to user space. best regards, Phil