From nobody Mon Jun 16 02:31:54 2025 X-Original-To: dev-commits-src-all@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 4bLDXs6QM7z5yLbk; Mon, 16 Jun 2025 02:31:57 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta004.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4bLDXs4G5Wz3GF3; Mon, 16 Jun 2025 02:31:57 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4001a.ext.cloudfilter.net ([10.228.9.142]) by cmsmtp with ESMTPS id QoC9uMSa15MqyQzdcuwJ64; Mon, 16 Jun 2025 02:31:56 +0000 Received: from spqr.komquats.com ([70.66.136.217]) by cmsmtp with ESMTPSA id QzdautpzOWX70QzdbuvwwX; Mon, 16 Jun 2025 02:31:56 +0000 X-Auth-User: cschuber X-Authority-Analysis: v=2.4 cv=d71WygjE c=1 sm=1 tr=0 ts=684f821c a=h7br+8Ma+Xn9xscxy5znUg==:117 a=h7br+8Ma+Xn9xscxy5znUg==:17 a=kj9zAlcOel0A:10 a=6IFa9wvqVegA:10 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=YxBL1-UpAAAA:8 a=EOVmtpnw_-W6AFn27tQA:9 a=CjuIK1q_8ugA:10 a=LK5xJRSDVpKd5WXXoEvA:22 a=Ia-lj3WSrqcvXOmTRaiG:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 700E6F8A; Sun, 15 Jun 2025 19:31:54 -0700 (PDT) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 3D2B730C; Sun, 15 Jun 2025 19:31:54 -0700 (PDT) X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.8+dev Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Ronald Klop cc: Cy Schubert , dev-commits-src-main@FreeBSD.org, dev-commits-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: git: b6e33f0cd536 - main - rc.d/mountcritlocal: Make sure zpools are imported for legacy ZFS In-reply-to: <240137891.21754.1749997280448@localhost> References: <240137891.21754.1749997280448@localhost> Comments: In-reply-to Ronald Klop message dated "Sun, 15 Jun 2025 16:21:20 +0200." List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 15 Jun 2025 19:31:54 -0700 Message-Id: <20250616023154.3D2B730C@slippy.cwsent.com> X-CMAE-Envelope: MS4xfJKEjef0td0njZq9S4Rap6bfylYZUBseueFKJfO+QuSzizOSULHR6NFKjzRwXb7lWhUJINpzqzxj60bgKWxKmW92cq5SLRPs9w9lUi9EbGVxRrAJ1eL+ qEDX4RHecUI5KMxOW0dw8yk/Kq+zbR+riGfJ5vTjlH8uJSaCIp+iSyqOd+FznOicRKyhjSN8k9uv7DElWV6+bdN01keiHopVvA2rPKiIXR1QgDRJBr9Xiqc7 Gsx5MrmQDXSEH8HVFv5duOF5ieU29SZw8xKNpOOVPGotZHQHBC91stzgfwWoTJIwE0LThv/8z3jCYeJOflcaTqsvjsP68gZqrLi6MM8tLGMm1KKpMC6y7FeD of7vnwpa X-Rspamd-Queue-Id: 4bLDXs4G5Wz3GF3 X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16509, ipnet:3.96.0.0/15, country:US] In message <240137891.21754.1749997280448@localhost>, Ronald Klop writes: > ------=_Part_21753_1823422774.1749997280446 > Content-Type: text/plain; charset=us-ascii; format=flowed > Content-Transfer-Encoding: 7bit > > Van: Cy Schubert > Datum: 15 juni 2025 07:08 > Aan: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits > -src-main@FreeBSD.org > Onderwerp: git: b6e33f0cd536 - main - rc.d/mountcritlocal: Make sure zpools > are imported for legacy ZFS > > > > > > > The branch main has been updated by cy: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=b6e33f0cd53683e06570606d5bd88f > c04a4b76fe > > > > commit b6e33f0cd53683e06570606d5bd88fc04a4b76fe > > Author: Cy Schubert > > AuthorDate: 2025-06-14 13:16:16 +0000 > > Commit: Cy Schubert > > CommitDate: 2025-06-15 04:39:36 +0000 > > > > rc.d/mountcritlocal: Make sure zpools are imported for legacy ZFS > > > > Legacy ZFS uses fstab to mount its datasets. In an attempt to fix > > another problem 900bc0206348 broke legacy ZFS in fstab(5). This > > comit works around the problem by mountcritlocal scanning /etc/fstab > > for zfs mountpoint and if any are found invoke /etc/rc.d/zpool start. > > > > Reviewed by: imp > > Differential Revision: https://reviews.freebsd.org/D50844 > > --- > > libexec/rc/rc.d/mountcritlocal | 9 +++++++++ > > 1 file changed, 9 insertions(+) > > > > diff --git a/libexec/rc/rc.d/mountcritlocal b/libexec/rc/rc.d/mountcritloca > l > > index f91eaf44457c..6dce672657fc 100755 > > --- a/libexec/rc/rc.d/mountcritlocal > > +++ b/libexec/rc/rc.d/mountcritlocal > > @@ -27,6 +27,15 @@ mountcritlocal_start() > > ;; > > esac > > > > + while read a b vfstype rest; do > > + if [ "$vfstype" = "zfs" -a "$a" != "#" ]; then > > + # zpool is needed for legacy ZFS > > + echo 'Importing zpools for legacy ZFS' > > + /etc/rc.d/zpool start > > + break > > + fi > > + done < /etc/fstab > > + > > # Mount everything except nfs filesystems. > > startmsg -n 'Mounting local filesystems:' > > mount_excludes='no' > > > > > > > > > > > > > Does this mean that a comment # must always be folllowed by a whitespace? Yes. It's a hack but it's the only way without grep (when /usr may not be mounted). In the very worst case rc.d/zpool will be needlessly executed. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e**(i*pi)+1=0