From nobody Thu Jul 10 17:54:51 2025 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4bdMtx18GBz61LDR for ; Thu, 10 Jul 2025 17:55:05 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4bdMtw0cypz3L1g; Thu, 10 Jul 2025 17:55:03 +0000 (UTC) (envelope-from kostikbel@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=none; spf=softfail (mx1.freebsd.org: 2001:470:d5e7:1::1 is neither permitted nor denied by domain of kostikbel@gmail.com) smtp.mailfrom=kostikbel@gmail.com; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=gmail.com (policy=none) Received: from tom.home (kib@localhost [127.0.0.1] (may be forged)) by kib.kiev.ua (8.18.1/8.18.1) with ESMTP id 56AHsq12038653; Thu, 10 Jul 2025 20:54:55 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua 56AHsq12038653 Received: (from kostik@localhost) by tom.home (8.18.1/8.18.1/Submit) id 56AHspk0038652; Thu, 10 Jul 2025 20:54:51 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 10 Jul 2025 20:54:51 +0300 From: Konstantin Belousov To: Rick Macklem Cc: FreeBSD CURRENT , Alexander Motin Subject: Re: RFC: Documenting weird case w.r.t. Solaris style extended attr (ZFS) Message-ID: References: List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FORGED_GMAIL_RCVD,FREEMAIL_FROM, NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on tom.home X-Spamd-Result: default: False [1.07 / 15.00]; NEURAL_SPAM_MEDIUM(1.00)[1.000]; NEURAL_SPAM_LONG(1.00)[1.000]; NEURAL_HAM_SHORT(-0.93)[-0.934]; MIME_GOOD(-0.10)[text/plain]; DMARC_POLICY_SOFTFAIL(0.10)[gmail.com : No valid SPF, No valid DKIM,none]; RCVD_TLS_LAST(0.00)[]; TAGGED_RCPT(0.00)[]; ASN(0.00)[asn:6939, ipnet:2001:470::/32, country:US]; MIME_TRACE(0.00)[0:+]; MISSING_XM_UA(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; FREEMAIL_FROM(0.00)[gmail.com]; FREEMAIL_TO(0.00)[gmail.com]; R_DKIM_NA(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; FROM_HAS_DN(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; HAS_XAW(0.00)[]; R_SPF_SOFTFAIL(0.00)[~all]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; MLMMJ_DEST(0.00)[freebsd-current@freebsd.org]; ARC_NA(0.00)[] X-Rspamd-Queue-Id: 4bdMtw0cypz3L1g X-Spamd-Bar: + On Thu, Jul 10, 2025 at 06:59:35AM -0700, Rick Macklem wrote: > I've done a series of commits to main to add support for > Solaris style extended attributes (which I called named attributes, > which is the NFSv4 term for them). > > ZFS is currently the only local file system that will support them > and only if the ZFS property "xattr" is set to "dir". > > If "zfs set xattr=dir " is done before any user namespace > extended attributes are created for files via extattr(2), I think > everything makes sense. > --> There is one set of extended attributes that are visible through > both extattr(2) and named_attribute(7). > > However, if extattr(2) is used to create user namespace extended > attributes when "xattr=sa" and then "xattr" is set to "dir", these > extended attributes are only visible to extattr(2) and not > named_attribute(7). > --> I will note that you can use tar(1) to copy the files and then the > extended attributes become visible to named_attribute(7). > I do not see any way to avoid this, but it should at least be documented. > > So, where do you think I should document this? > - I could put it in named_attribute(7) as an additional case where > the two extended attribute system call mechanisms cannot be > used. (I was hesitant, since this is ZFS specific). > Does this sound ok, or is there somewhere better to put it? > (zfsprops(7) is another possibility, since it already documents > "sa" and "dir" values for the "xattr" property.) I do not see why not put it to named_attribute(7) page. We do not have a ban on adding important fs-specific notes in the generic documentation. More, I think it is a proper place to document the details instead of spreading them into corners. BTW, would you consider adding named attrs support to tmpfs? I believe it is useful for tmpfs to be on par with the union of all features of our local filesystems.