Re: [nfsv4] Can NFSv4.2 operations be optional on a per server file system basis?

Thomas Haynes <loghyr@gmail.com> Thu, 21 October 2021 18:20 UTC

Return-Path: <loghyr@gmail.com>
X-Original-To: nfsv4@ietfa.amsl.com
Delivered-To: nfsv4@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E5EA83A07A1 for <nfsv4@ietfa.amsl.com>; Thu, 21 Oct 2021 11:20:59 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LoAttluECPla for <nfsv4@ietfa.amsl.com>; Thu, 21 Oct 2021 11:20:55 -0700 (PDT)
Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E7CCF3A079E for <nfsv4@ietf.org>; Thu, 21 Oct 2021 11:20:54 -0700 (PDT)
Received: by mail-pj1-x1036.google.com with SMTP id s61-20020a17090a69c300b0019f663cfcd1so3808277pjj.1 for <nfsv4@ietf.org>; Thu, 21 Oct 2021 11:20:54 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:message-id:mime-version:subject:date:in-reply-to:cc:to :references; bh=G37xjoPXdY3fGPsMfBtDinnlkWiLA4rO3NfnIroUOsg=; b=M1X3QLO+nM6rPQoqlnCiM51FMv8Lbv4EVIC3r5yIE/pF6x/Tewm1ooPmXxGcuufIlF hzjX1ZLf+YJdKWChOuv/ZCcFaeUJ7/K728spfCyzD+gtfJMLva4PG6RcybJEcCfJjdYJ HQI+q+NdaNgRpNVeZfMiVn+01bbSnVNs3uU9whW8LQEfMsUl8S5if8U/1CA2SFY97t4U jhOLWl2+T5RAA2pufRKV+4zLDixKIcjF3wgWGfrApInAZvmoKkZq8JFiRL1CCMHK4USt LDoH2lt2MjMhpf8SlG39FUko6ZINcOxxUKFNagOBAi6ztRmb5Y29cBfYGzuBXhKq47DQ Qizw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:message-id:mime-version:subject:date :in-reply-to:cc:to:references; bh=G37xjoPXdY3fGPsMfBtDinnlkWiLA4rO3NfnIroUOsg=; b=JHe/w3iCFUqoR7LCyWuLx2XwkS5hZUq9ZqlnnsHt9CZyaP7v/O8xLbfIxJEKG6xVaU WPB1v+U1C8+rxAG2OyJUYXQp1tgXfsXLds3mx0JqCwcH3wLU0XgZXjVWPIZS1rYN/yJj 27xWqtiwE6amAskWMPBwkijsRRTclSRGZNX7+PlSN+lJyvwnGUGHnKijYUIrcCZd+G4C 4dC85gnI0uxEtaaomUUWsNiK4lgV7TZrU7hGifAr6Dy2qWC0WSE/RKrh57603Gqu6Ern nLvuoMbs9Yt+XpgmB7homRiV2l25afxi45KDcdKBya31nOoi7tWPbBS/uZuUPIOKFKMF J4+g==
X-Gm-Message-State: AOAM532ezFE3Xc1WLhPgJiPL4aD4C4O8JNl8t9vXHbLzASzO1bKnAANb 6yPQbqqryqzkhxdZlzFft2Sy6z1zZC/Uuvg6
X-Google-Smtp-Source: ABdhPJyTk214n78qKVMlOoL63Mh9xRCdqbzVcyJLpdfJy6casZi5htcH1YsBT9xFafOI906UpI5ucw==
X-Received: by 2002:a17:90b:17d2:: with SMTP id me18mr8274150pjb.98.1634840453378; Thu, 21 Oct 2021 11:20:53 -0700 (PDT)
Received: from smtpclient.apple (c-69-181-67-218.hsd1.ca.comcast.net. [69.181.67.218]) by smtp.gmail.com with ESMTPSA id k35sm10280355pjc.53.2021.10.21.11.20.52 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 21 Oct 2021 11:20:53 -0700 (PDT)
From: Thomas Haynes <loghyr@gmail.com>
Message-Id: <FA61F429-EECE-44F1-876D-91B912750F8A@gmail.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_DB259759-E7CB-4D61-8106-4B0571152A84"
Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\))
Date: Thu, 21 Oct 2021 11:20:51 -0700
In-Reply-To: <CADaq8jd-YHPK400UnPPUyBB8mV-pVUJgC4yTwZu90Qmauxh9aQ@mail.gmail.com>
Cc: "J. Bruce Fields" <bfields@fieldses.org>, Rick Macklem <rmacklem@uoguelph.ca>, NFSv4 <nfsv4@ietf.org>
To: David Noveck <davenoveck@gmail.com>
References: <YQXPR0101MB0968D58C78D6E9ACBF7B8A3FDDB49@YQXPR0101MB0968.CANPRD01.PROD.OUTLOOK.COM> <683B4D58-BFDF-465D-9E77-607819354EAA@gmail.com> <YQXPR0101MB0968AE1F6DD2D47EC458B7D7DDB49@YQXPR0101MB0968.CANPRD01.PROD.OUTLOOK.COM> <CADaq8jcN5tv7RMOY=_1BktUsWkqEmUy-w2aygiURBNZC9LBPDQ@mail.gmail.com> <YQXPR0101MB09684B8F12901E7B0A796A97DDB99@YQXPR0101MB0968.CANPRD01.PROD.OUTLOOK.COM> <20211019180511.GA18024@fieldses.org> <YQXPR0101MB0968B884DF6F28FFB3B5DCA2DDBE9@YQXPR0101MB0968.CANPRD01.PROD.OUTLOOK.COM> <E121A27A-7D25-4E86-B079-9FD4DE2BEEFA@gmail.com> <20211021021834.GB11612@fieldses.org> <CADaq8jd-YHPK400UnPPUyBB8mV-pVUJgC4yTwZu90Qmauxh9aQ@mail.gmail.com>
X-Mailer: Apple Mail (2.3654.120.0.1.13)
Archived-At: <https://mailarchive.ietf.org/arch/msg/nfsv4/RV_g0s5UU1DI4AyIvoFTCygKnAg>
Subject: Re: [nfsv4] Can NFSv4.2 operations be optional on a per server file system basis?
X-BeenThere: nfsv4@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: NFSv4 Working Group <nfsv4.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/nfsv4>, <mailto:nfsv4-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/nfsv4/>
List-Post: <mailto:nfsv4@ietf.org>
List-Help: <mailto:nfsv4-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/nfsv4>, <mailto:nfsv4-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 21 Oct 2021 18:21:00 -0000


> On Oct 20, 2021, at 10:02 PM, David Noveck <davenoveck@gmail.com> wrote:
> 
> Section 15.1.1.5 is a problem, although, as Bruce points out, it may not be problem returning NOTSUPP in practice.
> 

Perhaps the solution is to add a per-file system attribute to state whether or not it supports the optional feature.



> I'm thinking about updating this definition in rfc5661bis-03 together with dealing with a bunch of the remaining erratta reports and a few updates to the security discussion to respond to the changes in security-03.
> I would submit this right after security-03, even though the big split up of the bis is still a ways in the future.
> 
>  I think we can spend a few minutes discussing this at the meeting next week
> 
> 
> 
> On Wed, Oct 20, 2021, 10:18 PM J. Bruce Fields <bfields@fieldses.org <mailto:bfields@fieldses.org>> wrote:
> On Wed, Oct 20, 2021 at 06:50:29PM -0700, Thomas Haynes wrote:
> > Honestly I went with what I *thought* I intended. The best supporting
> > evidence is here:
> > 
> > 15.1.1.5.  NFS4ERR_NOTSUPP (Error Code 10004)
> > 
> >    Operation not supported, either because the operation is an
> >    OPTIONAL one and is not supported by this server or because the
> >    operation MUST NOT be implemented in the current minor version.
> > 
> > Which implies that the if OPTIONAL the operation is either entirely
> > supported by the server or not.
> > 
> > What is a client supposed to do if it tries ALLOCATE and the server
> > accepts it -- it tries again and the server replies NFS4ERR_NOTSUPP.
> 
> Return 0 to the application in the first case, and ENOTSUP in the
> second?  Is that a problem?
> 
> > Is the support based on time of day? Did something change on the
> > server?
> > 
> > You and I may know it is by filesystem, by how is that exposed to the
> > client?
> 
> Unless the client's trying to do some optimization, as in Rick's case,
> it doesn't sound likely to cause a problem.
> 
> I could see how EINVAL could cause practical problems, though.  E.g. an
> application probably knows how to handle NOTSUPP--it can fall back on
> writing zeroes, or something.  EINVAL, though, sounds like something's
> just broken, and it's not clear how to recover.
> 
> Ditto a tar application getting NOTSUPP on getxattr.
> 
> You're probably right on the letter of the spec.
> 
> But we definitely need a way to indicate these features aren't supported
> on a per-filesystem basis, and it sounds like NFS4ERR_NOTSUPP is likely
> to work in practice, so maybe just going with that is the least bad
> option....
> 
> --b.
> 
> _______________________________________________
> nfsv4 mailing list
> nfsv4@ietf.org <mailto:nfsv4@ietf.org>
> https://www.ietf.org/mailman/listinfo/nfsv4 <https://www.ietf.org/mailman/listinfo/nfsv4>