Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp5499374pxb; Wed, 26 Jan 2022 13:29:32 -0800 (PST) X-Google-Smtp-Source: ABdhPJzKmwlhlL7q7jgoPWkAPQg0RvRO1FoFPvu5hvtvDCBmoQTrS0mJ0CVOtTEM6VpSyMZALKM+ X-Received: by 2002:a17:902:aa84:: with SMTP id d4mr819101plr.137.1643232572285; Wed, 26 Jan 2022 13:29:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643232572; cv=none; d=google.com; s=arc-20160816; b=nLieUKWrDj2vlPQFimcqgq3z2caRF6nZS2Vr/B01MtmRNxzTN59BH5s8uV71E9a5ZA Q4pGOzXdUtJjq1jkNREVLgXpmVq+cvhkd30LCX0Nak+x6sRuzplIbJq01spR3xI+tHXK t6YjPrkMoX8blA/Bg1oTDBjwrRE9GfnTZJaCLuH46BdF4iXGq5yNl6QpTyL7LE7mSbYD PymmIoRp+VOdq8/Aj+l4Gmcn1uRxbx4wkQGw/kga2dIKUY5zkKO+1s88datLLJMivS9u 2FxYDzqJeSTOVB7UvZwTbxH44EhyeQKU/qlid72H3O+AoiQSTII+ER3Y6Xoz2y8DTMM1 eDtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature:dkim-filter; bh=2k3q5iQaiNYoh/n31aPakWLz8sUifTxpCo3fyZpyiHc=; b=GbZFhhQ7GF6bAqtu6RmM4uQCKK4CcC8JM4oHxrjtVvOG6d76TIriYE+loEQsEAtPEW 1GnivIv9EydEr+0kkyR2gPzsQL8/CeX5BHVw5W31/vMSCWEjGl55XmNAJP5VRcXb4fTl UxSTW9NILne/yYPhElfDmcDoXzg3Wh2Ke6dQHvbc/vDVkObcYV8+6GMurHqVPK3RX+Vf bxhvcYilIcL8ZubH7DK0T3dhxRjkvhvyakTiYWJT2Gv/GLEok6CiEIP8QqL4n0fDXj+C 2OfXmKfkv+aWou9lIFeblzRzaZKTyNGu/UyncssdDp3fkjYEm0lIxGgeW0vUNm6SvV9A 0R4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fieldses.org header.s=default header.b=vakr0p6y; 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 w4si239736plz.621.2022.01.26.13.29.00; Wed, 26 Jan 2022 13:29:32 -0800 (PST) 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=vakr0p6y; 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 S235077AbiAZOKz (ORCPT + 99 others); Wed, 26 Jan 2022 09:10:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54436 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233834AbiAZOKz (ORCPT ); Wed, 26 Jan 2022 09:10:55 -0500 Received: from fieldses.org (fieldses.org [IPv6:2600:3c00:e000:2f7::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D88DFC06161C for ; Wed, 26 Jan 2022 06:10:54 -0800 (PST) Received: by fieldses.org (Postfix, from userid 2815) id 73F9B70C2; Wed, 26 Jan 2022 09:10:53 -0500 (EST) DKIM-Filter: OpenDKIM Filter v2.11.0 fieldses.org 73F9B70C2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fieldses.org; s=default; t=1643206253; bh=2k3q5iQaiNYoh/n31aPakWLz8sUifTxpCo3fyZpyiHc=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=vakr0p6y0wv71vEdIRjh1y7ARZC6NddV0yNVl7/WuCLBn9AZ+C9eVFc2x6wd6q43w HV7XZpmlF5lgeumsDG06igEw/l3ILetYhvMgEyd9N8ZjHN2RsOhusl+olqyz2pspwB Vmnz+AI91jW+7/zUAoEEoAzznMCQsKQeL0+jjsAw= Date: Wed, 26 Jan 2022 09:10:53 -0500 From: "J. Bruce Fields" To: Volodymyr Khomenko Cc: linux-nfs@vger.kernel.org Subject: Re: [PATCH] pynfs minor: fixed Environment._maketree to use proper stateid during file write Message-ID: <20220126141053.GA29832@fieldses.org> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Fri, Jan 21, 2022 at 03:06:57PM +0200, Volodymyr Khomenko wrote: > > From 63c0711f9cd8f8c0aaff7d0116a42b5001bddcd2 Mon Sep 17 00:00:00 2001 > From: Volodymyr Khomenko > Date: Fri, 21 Jan 2022 14:52:28 +0200 > Subject: [PATCH] Minor: fixed Environment._maketree (used by init) to use > proper stateid during file write > > _maketree is a part of generic init sequence for server41tests so the code should be generic. > Using zero stateid (when "other" and "seqid" are both zero, the stateid is treated > as a special anonymous stateid) is a special use-case of anonymous access > so it must not be used during generic initialization. OK, applying, but I'm a little wary. If a server isn't accepting the zero stateid here then I think that's a server bug. --b. > > Signed-off-by: Volodymyr Khomenko > --- > nfs4.1/server41tests/environment.py | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/nfs4.1/server41tests/environment.py b/nfs4.1/server41tests/environment.py > index 14b0902..0b7c976 100644 > --- a/nfs4.1/server41tests/environment.py > +++ b/nfs4.1/server41tests/environment.py > @@ -198,7 +198,7 @@ class Environment(testmod.Environment): > log.warning("could not create /%s" % b'/'.join(path)) > # Make file-object in /tree > fh, stateid = create_confirm(sess, b'maketree', tree + [b'file']) > - res = write_file(sess, fh, self.filedata) > + res = write_file(sess, fh, self.filedata, stateid=stateid) > check(res, msg="Writing data to /%s/file" % b'/'.join(tree)) > res = close_file(sess, fh, stateid) > check(res) > -- > 2.25.1 >