Migration to OpenZFS experience? reddit / freebsd ---------------------------------------------------------------------- jkoopmann72 · 2020-10-24 07:41 Hi, thinking about switching to OpenZFS on my FreeBSD 12. I have two pools one of which is zroot so I am booting of ZFS currently. Is it as easy to switch from zfs_load to openzfs_load in rc.conf and boot.conf and reboot (after installing OpenZFS ports). Anything to look out for? Has someone already done this and can share some experience? Why I want this: ZFS native encryption. :-) Thanks! ---------------------------------------------------------------------- Holy_Pee_Shooter_PvZ · 2020-10-24 07:53 I tried openZFS out earlier. The experience is very smooth. It just works ---------------------------------------------------------------------- jkoopmann72 · 2020-10-24 08:29 Incl migration of existing pools (incl zroot)? Do I need to upgrade to 12.x first? I am on 12.1-RELEASE-p9 now. ---------------------------------------------------------------------- Holy_Pee_Shooter_PvZ · 2020-10-24 13:00 Yep! I am using FBSD 12.1 & OpenZFS 0.8.x ---------------------------------------------------------------------- jkoopmann72 · 2020-10-24 13:20 I managed to get it working. HOWEVER: After reboot only zroot is mounted and only some of the datasets. A zpool import for the other datasets works and zfs mount -a as well (with the exception of the encrypted ones). But I have to do this after every reboot. Something is not right. Any experience with this? ---------------------------------------------------------------------- Holy_Pee_Shooter_PvZ · 2020-10-24 13:50 What's the output of your zpool history $POOL ? ---------------------------------------------------------------------- jkoopmann72 · 2020-10-24 13:57 Hi, first to note is that I replaced zfs\_enable="YES" with openzfs\_enable="YES" since this was somewhere on the net. And I did not check this. since there is no openzfs script but a zfs script this surely was incorrect and explains why not all datasets were mounted. Not sure it explains the missing pools though. ​ zpool history shows zpool import $POOL zpool upgrade $POOL and then zfs commands I issued. Nothing else striking the eye. ---------------------------------------------------------------------- Holy_Pee_Shooter_PvZ · 2020-10-24 14:08 After installing openzfs, where will be two zfs/zpool binaries: /sbin/zfs & /usr/local/sbin/zfs Make sure you are using /usr/local/sbin/zfs. Maybe your dataset has canmount=noauto/off, or other settings which prevent zfs from mounting it. Check the output of "zfs get all". Some properties are openzfs only, so maybe openzfs assigns a random value to it which you don't desire. ---------------------------------------------------------------------- dddddavidddd · 2020-10-24 15:20 I'm running 12.1 with OpenZFS. I had lots of weird conflicts with the system ZFS, so I built the OS without ZFS support, installed to a UFS partition, and then keep my user data in a zpool. ---------------------------------------------------------------------- Zaechus · 2020-10-24 21:16 I tried out OpenZFS for a long time, and I gotta say it works smoothly. I switched back to Btrfs tho because it works just as well. ---------------------------------------------------------------------- jkoopmann72 · 2020-10-24 21:22 I am using /usr/local/sbin/zpool. Could only be a pool property. I already looked for something with no luck. Let’s see what happens on next reboot. Thanks so much for your assistance! ---------------------------------------------------------------------- dddddavidddd · 2020-10-24 21:49 In my case, this was because of rc.d scripts (& maybe the loader) trying to use the system zfs binaries instead of the OpenZFS binaries. ---------------------------------------------------------------------- grahamperrin · 2020-12-01 07:28 From , with added emphasis: > … **Do not upgrade root pools** until the loader is updated to support zstd. Furthermore, we caution against 'zpool upgrade' for the next few weeks. … – and so on. ### Encryption GELI-encrypted system at `ada0p4`. USB hard disk drive at `da0` with OpenZFS-encrypted non-system stuff. If the USB hard disk drive is connected when the computer starts (or restarts), the system will not boot; no bootable system found. grahamperrin@mowa219-gjp4-8570p:~ % lsblk DEVICE MAJ:MIN SIZE TYPE LABEL MOUNT ada0 0:133 466G GPT - - ada0p1 0:135 200M efi gpt/efiboot0 - ada0p2 0:137 512K freebsd-boot gpt/gptboot0 - -:- 492K - - - ada0p3 0:139 16G freebsd-swap gpt/swap0 SWAP ada0p3.eli 1:250 16G freebsd-swap - SWAP ada0p4 0:141 450G freebsd-zfs gpt/zfs0 ada0p4.eli 0:152 450G - - - -:- 4.0K - - - da0 2:40 466G GPT - - -:- 1.0M - - - da0p1 2:41 466G freebsd-zfs gpt/efiboot0 grahamperrin@mowa219-gjp4-8570p:~ % zfs get compression,encryptionroot Transcend Transcend/VirtualBox NAME PROPERTY VALUE SOURCE Transcend compression zstd local Transcend encryptionroot - - Transcend/VirtualBox compression zstd inherited from Transcend Transcend/VirtualBox encryptionroot Transcend/VirtualBox - grahamperrin@mowa219-gjp4-8570p:~ % date ; uname -v Tue 1 Dec 2020 07:21:58 GMT FreeBSD 13.0-CURRENT #72 r367936: Sun Nov 22 21:46:00 GMT 2020 root@mowa219-gjp4-8570p:/usr/obj/usr/src/amd64.amd64/sys/GENERIC- NODEBUG grahamperrin@mowa219-gjp4-8570p:~ % geli list Geom name: ada0p4.eli State: ACTIVE EncryptionAlgorithm: AES-XTS KeyLength: 256 Crypto: accelerated software Version: 7 UsedKey: 0 Flags: BOOT, GELIBOOT KeysAllocated: 113 KeysTotal: 113 Providers: 1. Name: ada0p4.eli Mediasize: 482717200384 (450G) Sectorsize: 4096 Mode: r1w1e1 Consumers: 1. Name: ada0p4 Mediasize: 482717204480 (450G) Sectorsize: 512 Stripesize: 4096 Stripeoffset: 0 Mode: r1w1e1 Geom name: ada0p3.eli State: ACTIVE EncryptionAlgorithm: AES-XTS KeyLength: 128 Crypto: accelerated software Version: 7 Flags: ONETIME, W-DETACH, W-OPEN, AUTORESIZE KeysAllocated: 4 KeysTotal: 4 Providers: 1. Name: ada0p3.eli Mediasize: 17179869184 (16G) Sectorsize: 4096 Mode: r1w1e0 Consumers: 1. Name: ada0p3 Mediasize: 17179869184 (16G) Sectorsize: 512 Stripesize: 4096 Stripeoffset: 0 Mode: r1w1e1 grahamperrin@mowa219-gjp4-8570p:~ % ---------------------------------------------------------------------- grahamperrin · 2020-12-12 09:30 Also [Upgrading from 'universal' zfs version - seeking advice : freebs d](https://np.reddit.com/r/freebsd/comments/jojmx1/upgrading_from_univ ersal_zfs_version_seeking/) ---------------------------------------------------------------------- vertigoacid · 2021-01-01 21:46 Did you ever come up with a solution here? I am seeing the same thing, root pool gets imported but not fully mounted, and my second pool doesn't get imported at all ---------------------------------------------------------------------- jkoopmann72 · 2021-01-01 22:51 Have not rebooted yet.... so hard to tell.