persistent integer divide fault panic in zfs_rmnode

Xin Li delphij at delphij.net
Wed Jan 27 23:23:24 UTC 2021


On 1/27/21 10:15, Steven Schlansker wrote:
> Does anybody have any suggestions as to what I can try next regarding this
> panic?
> 
> At this point the only path forward I see is to declare the zpool corrupt
> and attempt to
> move all the data off, destroy, and migrate back, and hope the recreated
> pool does not tickle this bug.
> 
> That would be a pretty disappointing end to a long fatal-problem-free run
> with ZFS.

Could you please try the attached patch? (Full context:
https://github.com/openzfs/zfs/issues/8778 )

Cheers,
-------------- next part --------------
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c
index 45ac4b796fd..b6a495d0172 100644
--- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c
+++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c
@@ -706,8 +706,8 @@ get_next_chunk(dnode_t *dn, uint64_t *start, uint64_t minimum, uint64_t *l1blks)
 	uint64_t blks;
 	uint64_t maxblks = DMU_MAX_ACCESS >> (dn->dn_indblkshift + 1);
 	/* bytes of data covered by a level-1 indirect block */
-	uint64_t iblkrange =
-	    dn->dn_datablksz * EPB(dn->dn_indblkshift, SPA_BLKPTRSHIFT);
+	uint64_t iblkrange = (uint64_t)dn->dn_datablksz *
+	    EPB(dn->dn_indblkshift, SPA_BLKPTRSHIFT);
 
 	ASSERT3U(minimum, <=, *start);
 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-fs/attachments/20210127/38ab15ee/attachment.sig>


More information about the freebsd-fs mailing list