HomeFreeBSD

libbe(3): simplify import, allow replication streams

Description

libbe(3): simplify import, allow replication streams

Previously, we directly used libzfs_core's lzc_receive to import to a
temporary snapshot, then cloned the snapshot and setup the properties. This
failed when attempting to import replication streams with questionable
error.

libzfs's zfs_receive is a much better fit here, so we now use it instead
with the destination dataset and let libzfs take care of the dirty details.
be_import is greatly simplified as a result.

Reported by: Marie Helene Kvello-Aune <freebsd@mhka.no>
MFC after: 1 week

Details

Provenance
kevansAuthored on
Parents
rS343334: MFC r342558: Switch from mutexes to atomics in GEOM_DEV I/O path.
Branches
Unknown
Tags
Unknown