Transfer existing Linux pool to FreeBSD?

Generally speaking, yes, you can pass pools back and forth between Linux distros and FreeBSD without issue. The potential issues arise when one distro is much newer than the other, and therefore has a newer OpenZFS than the other; if the newer version is the source and has enabled feature flags that change the on-disk storage format, then you won’t be able to import the pool on the older side.

These days, what this typically comes down to is “as long as the version of FreeBSD is newer than the one you were using in Linux, it’ll be fine” and vice versa for changes in the other direction. You’re more likely to have a real problem when you use a NAS distro that might have gone a bit cowboy with the codebase; ixSystems (makers of TrueNAS) have been known to enable features they’ve been working on in-house that aren’t in any production version of OpenZFS yet.

Essentially, what you want to do here is just boot your system from a FreeBSD live installer, then check to make sure you can import the pool. If the pool imports and you can see your data, you’re good to go, and you can simply export it again and your “real” system will automatically import it again on boot. Then, you can start work on actual migration.

1 Like