Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1398121pxk; Fri, 4 Sep 2020 08:25:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzlWGlKpgXxdgNAmWNgBuScAR0t21pVT6wth4/Hn6krg/ABYyTblaw6iqlnCMHK8ab7xTHF X-Received: by 2002:a50:c292:: with SMTP id o18mr9419510edf.90.1599233142417; Fri, 04 Sep 2020 08:25:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599233142; cv=none; d=google.com; s=arc-20160816; b=uvpr5O0bUzUOz2XJRpXRYR2toEAsG9rDl7WIPqcP7qUjaX053lOHAfptgjSFcsrBsq syMq1GenFy/az7hZQT5Kow8PKW13XJhx1QJLGN/RmU5gLJk+h8Z99fKL/X//dJoe6yY7 ZyY1vP1KTuy+jfTjXQ3CjJCVcRl3hzgK9FwNogETJil6RUu6K/Hxc2o+Rg/QB9ZWPWbl hUrmHxU3EppC//wxVun2N258stncOviehjVrNAf67vH64LEONTYID8blDW9EJy5pAj8Q LYTeUBx0UfEg2tludSXXkRF1s5FWo6v3aM8MIxnCorMNmoFX8XWpkTNMzPNWCSfE+QXo JBcA== 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-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:dkim-filter; bh=Hd7d/Ov53FZg42ZH9GAiN85Zp3KOdBt8VgfG6P0v2I8=; b=QlKjXB7WlTSLY+reoWhJRD56iG5YBBSu3vogaXkuFfzk0CO06qsU29jbSXepBTpqPF G4lGtS0S9mGAXeydIU+41G75K7nPKu9KRPO43sJ95FYLTeFh7rnVAQxLkuanVSuhM2oI ucXib/Oim//3b0V8Sp7YYKenAh6td7QWhp2UoEjsdK5jHkEsdM+rI2/T0a8Uwo9CrH5e 3J6qaT/jnsMQz7P6bxnbs3OurUeHYEFWURxHKZS6rWdaCjrAUyEeNEL55B6d78w/ljRR TJfgP8YHQ9vPjHFaMpa+CCy0Y3lgPWp24iKEAHrdY3DyTgT2PgpcGjMRdaf3jASPEAzj d4qQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fieldses.org header.s=default header.b=lVrONGur; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s7si4018573edj.515.2020.09.04.08.25.11; Fri, 04 Sep 2020 08:25:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@fieldses.org header.s=default header.b=lVrONGur; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730977AbgIDPYg (ORCPT + 99 others); Fri, 4 Sep 2020 11:24:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40496 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730967AbgIDPYa (ORCPT ); Fri, 4 Sep 2020 11:24:30 -0400 Received: from fieldses.org (fieldses.org [IPv6:2600:3c00:e000:2f7::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A7E73C061244 for ; Fri, 4 Sep 2020 08:24:30 -0700 (PDT) Received: by fieldses.org (Postfix, from userid 2815) id 4D3C11509; Fri, 4 Sep 2020 11:24:29 -0400 (EDT) DKIM-Filter: OpenDKIM Filter v2.11.0 fieldses.org 4D3C11509 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fieldses.org; s=default; t=1599233069; bh=Hd7d/Ov53FZg42ZH9GAiN85Zp3KOdBt8VgfG6P0v2I8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=lVrONGurzomW3zq0zTRRlmz3usGCEvL2R5CtN2A41Kqx71VENf51caaEMFvISCQLZ 2pqU4gr6R1zUnWrEuQ7c4LPKqlBMphEyzz6P4lSxqQTHI9PZBTGdZn9xZ4f9hS6UlQ xB6t+G9x36A523Je90sj9Ic/+I0GJyvVLRoi9Um4= Date: Fri, 4 Sep 2020 11:24:29 -0400 From: Bruce Fields To: Chuck Lever Cc: Bruce Fields , Anna Schumaker , Linux NFS Mailing List Subject: Re: [PATCH v4 2/5] NFSD: Add READ_PLUS data support Message-ID: <20200904152429.GA1738@fieldses.org> References: <20200901191854.GD12082@fieldses.org> <20200904135259.GB26706@fieldses.org> <00931C34-6C86-46A2-A3B3-9727DA5E739E@oracle.com> <20200904140324.GC26706@fieldses.org> <164C37D9-8044-4CF4-99A1-5FB722A16B8E@oracle.com> <20200904142923.GE26706@fieldses.org> <20200904144932.GA349848@pick.fieldses.org> <45DCF35D-A919-4A99-9B6D-0952ED0A78E5@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <45DCF35D-A919-4A99-9B6D-0952ED0A78E5@oracle.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Fri, Sep 04, 2020 at 10:58:43AM -0400, Chuck Lever wrote: > > What do you think might go wrong otherwise? > > I don't see a data corruption issue here, if that's what > you mean. > > Suppose the server has a large file with a lot of holes, > and these holes are all unallocated. This might be > typical of a container image. > > Suppose further the client is able to punch holes in a > destination file as a thin provisioning mechanism. > > Now, suppose we copy the file via TCP/READ_PLUS, and > that preserves the holes. > > Copy with RDMA/SEEK_HOLE and maybe it doesn't preserve > holes. The destination file is now significantly larger > and less efficiently stored. > > Or maybe it's the other way around. Either way, one > mechanism is hole-preserving and one isn't. > > A quality implementation would try to preserve holes as > much as possible so that the server can make smart storage > provisioning decisions. OK, I can see that, thanks. So, I was trying to make sure we handle cases where SEEK results are weirdly aligned or segments returned are very small. I don't think that'll happen with any "normal" setup, I think it probably requires strange FUSE filesystems or unusual races or malicious users or some combination thereof. So suboptimal handling is OK, I just don't want to violate the protocol or crash or hang or something. I'm not seeing the RDMA connection, by the way. SEEK and READ_PLUS should work the same over TCP and RDMA. --b.