HomeFreeBSD

Fix raw receive with different indirect block size.

Description

Fix raw receive with different indirect block size.

Unlike regular receive, raw receive require destination to have the
same block structure as the source. In case of dnode reclaim this
triggers two special cases, requiring special handling:

  • If dn_nlevels == 1, we can change the ibs, but dnode_set_blksz()

should not dirty the data buffer if block size does not change, or
durign receive dbuf_dirty_lightweight() will trigger assertion.

  • If dn_nlevels > 1, we just can't change the ibs, dnode_set_blksz()

would fail and receive_object would trigger assertion, so we should
destroy and recreate the dnode from scratch.

Reviewed-by: Paul Dagnelie <pcd@delphix.com>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Sponsored by: iXsystems, Inc.
Closes #15039

Details

Provenance
mavAuthored on Jul 14 2023, 11:16 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jul 20 2023, 3:59 PM
Parents
rG6e79bcd3569a: Fix remount when setting multiple properties.
Branches
Unknown
Tags
Unknown