From nobody Thu Nov 10 02:52:08 2022 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 4N75wB61ymz4dFHd; Thu, 10 Nov 2022 02:52:10 +0000 (UTC) (envelope-from gjb@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (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-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "freefall.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4N75wB5JVHz3wwh; Thu, 10 Nov 2022 02:52:10 +0000 (UTC) (envelope-from gjb@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1668048730; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=aL7ryB+i71bxWFAgtL5oINv6e2fyPeYsfH4N+32rpjI=; b=DoVhGcrC0p0zbt8/oU1/8DY0yQSAJYKL1L6BxkBcKxiDXrxJOvUwYHaMPvUU/6wPE452T9 5AhRKZZAymjVTDRAsALD408zpTGB0IiwRVLnnUhdudex6MtFpCdt15NdPWnBVKAF1DSuO4 TeJdC0sj2jlvWRUbRkCaOBK/y2gnQShfXnxDqy6xur8Hwi27TWWBoL3uCEuDRsVH7ZqptS HBk9FFbb+Tbs80iEL3ypb1pRRcmkldKXwZCaS6EMinK4s35ctNCMLx9y3ukB61bTygH7Bo UhRc+ljmxlaSIumn/JDy+I0UiMBFF8BR8QCHh37iSa8eR4zvddjqsRgLzBS4xQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1668048730; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=aL7ryB+i71bxWFAgtL5oINv6e2fyPeYsfH4N+32rpjI=; b=hLMkEjG1T+GKU1aZnsi9Z1NM2ilZaT3gKCxAJOIrxCoxk0ymEqp2bRQQRxYkhd0EA32L4m mf6M3OpnPOvmMUaQRETuZWT6bweXG2grnG5iNACZ6k8nF6ANL3K2U+1dbZHkNIxt/aa7NB h3z35WgUDhvuFbvDTbZdz+/PLw8cDDP+TZnWSBcX0PLSpElmIwH7LDInGjRGX9zP2XZCnq Oz8XACOyvtqecueUvw9ax/XKixPUTEer7Uh58PvNpvxVYkaagPWZFW/V1AT9F6CM9UVRnT JhsCNFa+8d2lSntTEcjq+uILCoQPB2j7rgLSsk85BL/2Fhdah985DEGa0M4Ijw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1668048730; a=rsa-sha256; cv=none; b=X/F24ua7SQBe7nwuonO59G0SDc/uei9PtW2LwAbtJHFiytPT9q9h1NmQLTEgQ+2VBEHWs2 ttuuO+adI1H5OoFQBlOaAqzQQ6BkD1YeudnjG8Xf2N6y1JmZZYnbYF28/Rx4QqReR/iMZv Y6BAlgjEnQX7umH0KoPiF1xoS/iNNfVVxRI5aEnpr+8aRZQcWbM0na0h4zN4Tjr8o2ctM5 lDNYAZnEh2jMxd/+ehci7JkD/uuH02RgnRRgrWDgeVR83yX9k6BokaafpMxMOgKZLB3Hxx UhFFEjDRLEwu9+Cjgx0fNviOX7aRJ/axy9SFHVFfXwiFjI8qojBTaCN3ATvdLA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from FreeBSD.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by freefall.freebsd.org (Postfix) with ESMTPS id 5583DDA0D; Thu, 10 Nov 2022 02:52:10 +0000 (UTC) (envelope-from gjb@freebsd.org) Date: Thu, 10 Nov 2022 02:52:08 +0000 From: Glen Barber To: Kirk McKusick Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 460ed6106cf0 - main - Add support for managing UFS/FFS snapshots to fsck_ffs(8). Message-ID: <20221110025208.GD52121@FreeBSD.org> References: <202211091846.2A9IkpA1013071@gitrepo.freebsd.org> <20221110023122.GC52121@FreeBSD.org> 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="IDYEmSnFhs3mNXr+" Content-Disposition: inline In-Reply-To: <20221110023122.GC52121@FreeBSD.org> X-ThisMailContainsUnwantedMimeParts: N --IDYEmSnFhs3mNXr+ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Nov 10, 2022 at 02:31:22AM +0000, Glen Barber wrote: > On Wed, Nov 09, 2022 at 06:46:51PM +0000, Kirk McKusick wrote: > > The branch main has been updated by mckusick: > >=20 > > URL: https://cgit.FreeBSD.org/src/commit/?id=3D460ed6106cf0854caff62e4e= eba8ffcd00ab0690 > >=20 > > commit 460ed6106cf0854caff62e4eeba8ffcd00ab0690 > > Author: Kirk McKusick > > AuthorDate: 2022-11-09 18:44:03 +0000 > > Commit: Kirk McKusick > > CommitDate: 2022-11-09 18:46:31 +0000 > >=20 > > Add support for managing UFS/FFS snapshots to fsck_ffs(8). > > =20 > > The kernel handles the managment of UFS/FFS snapshots. Since UFS/FFS > > updates filesystem data (rather than always writing changes to new > > locations like ZFS), the kernel must check every filesystem write > > to see if the block being written is part of a snapshot. If it is > > part of a snapshot, then the kernel must make a copy of the old > > block value into a newly allocated block for the snapshot before > > allowing the write to be done. Similarly, if a block is being freed, > > the kernel must check to see if it is part of a snapshot and let > > the snapshot claim the block rather than freeing it for future use. > > When a snapshot is freed, its blocks need to be offered to older > > snapshots and freed only if no older snapshots wish to claim them. > > =20 > > When snapshots were added to UFS/FFS they were integrated into soft > > updates and just a small part of the management of snapshots needed > > to be added to fsck_ffs(8) as soft updates minimized the set of > > snapshot changes that might need correction. When journaling was > > added to soft updates a much more complete knowledge of snapshots > > needed to be added to fsck_ffs(8) for it to be able to properly > > handle the filesystem changes that a journal rollback needs to do > > (specifically the freeing and allocation of blocks). Since this > > functionality was unavailable, the use of snapshots was disabled > > when running with journaled soft updates. > > =20 > > This set of changes imports the kernel code for the management of > > snapshots to fsck_ffs(8). With this code in place it will become > > possible to enable snapshots when running with journalled soft > > updates. The most immediate benefit will be the ability to use > > snapshots to take consistent filesystem dumps on live filesystems. > > Future work will be done to update fsck_ffs(8) to be able to use > > snapshots to run in background on live filesystems running with > > journaled soft updates. > > =20 >=20 > I think this broke the main build. >=20 > Notably: >=20 > % @@ -483,11 +507,38 @@ flush(int fd, struct bufarea *bp) > % } > % /* FALLTHROUGH */ > % default: > % + copyonwrite(&sblock, bp, std_checkblkavail); > % blwrite(fd, bp->b_un.b_buf, bp->b_bno, bp->b_size); > % break; >=20 > https://ci.freebsd.org/job/FreeBSD-main-i386-build/24590/console >=20 Oddly, the failure email I received was from stable/13, not main, but it was the exact same failure case according to the logs. That said, I see you had committed a fix already, so please disregard this email for now. Glen --IDYEmSnFhs3mNXr+ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEjRJAPC5sqwhs9k2jAxRYpUeP4pMFAmNsZ1gACgkQAxRYpUeP 4pM+FA/6AiVLjPvVSmdE3VMpOHdPM6d57pc2BFdqtwbCe7+AUpBH2kLBhRXe1CZX xGBglCnBE02f/J7kSoN4s35fWMjjWc0dcEakKfBqma4PYYrbt7q2S0bCUkasWL7C aMk4Mk8HZ/P0QXlcv2V+u/sNCHoIAieRu6llYqAObx34jIJorjOUAWs72LNEP2+f esv3GznSSnCu4KskTfW0FBCgAbH2T7Xc+u1Psft4ZzZnlxj35zN7fVt9J02jOvWf jw1TS+htAh+zwSxDzZ9UtTBQDDn1TqwojcEnGPqyC6UjHvTE5QopJZbRc5EYEg5U 5iWUTJcjjIf5rd3Ya2cfsy62I1AkqTYP/iv7Ub/rLAXHbZOGCDK4dysRVz3JF5/C tQQQhw7OltQEp1cbY0VUBg4yLbw3I2SfFxPRIShi7OPkzP56aGvLuBg/ogkUGqxG rvuQyieSgDvG2NYsOToWNgHulwOjt5Hr5TwSkz/qqdMKnlJHWEscn1QbrVfJhkdt jOTYv6siqAGjYPBRfI5gemUkyw/sXV4wGxBFNz+pNAhHPEuX6TjQm5kjA5BYrnqJ t6yEYYCraQFSFZYZMQL2QhjUWiegAapwC2ryD10fkq7peePqLoL5aKKe6tzNO0gv 9l1A6229Zv4FUngDi6Jtl/tEDCiXr+2/rXO88J8MMuenUECxyvw= =O/pg -----END PGP SIGNATURE----- --IDYEmSnFhs3mNXr+--