ZFS [Solved]Migrate into another disk with other os

Hi all, this is my situation:
Code:
➜  ~ zpool list -v
NAME                                   SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
bsdpool                                944G  9.26G   935G        -         -     0%     0%  1.00x    ONLINE  -
  diskid/DISK-0385079B115D00656692p4   944G  9.26G   935G        -         -     0%  0.98%      -    ONLINE
gpool                                  298G  7.74G   290G        -         -     0%     2%  1.00x    ONLINE  /mnt/uno
  diskid/DISK-2140JY447104p1           298G  7.74G   290G        -         -     0%  2.59%      -    ONLINE

where bsdpool is pool of freebsd and gpool ghostbsd

Code:
➜  ~ zfs list -t filesystem                                                       
NAME                   USED  AVAIL     REFER  MOUNTPOINT
bsdpool               9.25G   905G       96K  /bsdpool
bsdpool/ROOT          7.57G   905G       96K  none
bsdpool/ROOT/default  7.57G   905G     7.57G  /
bsdpool/tmp            208K   905G      208K  /tmp
bsdpool/usr           1.68G   905G       96K  /usr
bsdpool/usr/home       153M   905G      153M  /usr/home
bsdpool/usr/ports      807M   905G      807M  /usr/ports
bsdpool/usr/src        760M   905G      760M  /usr/src
bsdpool/var            884K   905G       96K  /var
bsdpool/var/audit       96K   905G       96K  /var/audit
bsdpool/var/crash       96K   905G       96K  /var/crash
bsdpool/var/log        348K   905G      348K  /var/log
bsdpool/var/mail       152K   905G      152K  /var/mail
bsdpool/var/tmp         96K   905G       96K  /var/tmp
gpool                 7.74G   281G       96K  legacy
gpool/ROOT            7.57G   281G       96K  legacy
gpool/ROOT/default    7.57G   281G     7.57G  /mnt/uno
gpool/tmp              148K   281G      148K  /mnt/uno/tmp
gpool/usr              170M   281G       96K  /mnt/uno/usr
gpool/usr/home         169M   281G      169M  /mnt/uno/usr/home
gpool/usr/ports         96K   281G       96K  /mnt/uno/usr/ports
gpool/usr/src           96K   281G       96K  /mnt/uno/usr/src
gpool/var              480K   281G       96K  /mnt/uno/var
gpool/var/audit         96K   281G       96K  /mnt/uno/var/audit
gpool/var/crash         96K   281G       96K  /mnt/uno/var/crash
gpool/var/mail          96K   281G       96K  /mnt/uno/var/mail
gpool/var/tmp           96K   281G       96K  /mnt/uno/var/tmp
there are two datasets

I would like to move ghost on disk contain freebsd, because I would like use only one partition.
I had already tried yesterday but something was wrong.
I had create snaphots for all ghost dataset and I move with zfs send/receive and after I made rollback.
I used the way I moved btrfs installations.

What I wrong?
 
Ok, I had hope that I can migrate similar to btrfs

So how can I, for example, create backup of ghostbsd and after install it on pre-existing partition contain dataset of freebsd?
 
I have difficulties understanding what you want to accomplish.
If you just want to move the data then zfs(8) is your friend.
Code:
zfs snapshot pool1/dataset@backup
zfs send pool1/dataset@backup | zfs receive pool2/dataset
Be careful when using the -R flag.
 
Very simple, I would like to have one only zfs partition with 2 or 3 os inside it. And that they are bootable
 
I'm going to reopen this thread because I would your advices for move my freebsd fresh install on disk with arch/void/opensuse with zfs.
There are my disks:
Code:
┌[zar_marco@arch-zfs] [/dev/pts/1]
└[~]> sudo fdisk -l                                                                                             
Disk /dev/nvme0n1: 931,51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: WDS100T1X0E-00AFY0                   
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: E7F8F894-3F81-11ED-95C0-C1AE74582F40

Dispositivo      Start       Fine    Settori  Size Tipo
/dev/nvme0n1p1    2048    1050623    1048576  512M EFI System
/dev/nvme0n1p2 1050624 1953523711 1952473088  931G Solaris root



Disk /dev/sda: 476,94 GiB, 512110190592 bytes, 1000215216 sectors
Disk model: 3JX013N       
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 33553920 bytes
Disklabel type: gpt
Disk identifier: CFE94F95-823B-11D1-A78E-416829E56C70

Dispositivo   Start       Fine   Settori   Size Tipo
/dev/sda1        40     532519    532480   260M EFI System
/dev/sda2    532520     533543      1024   512K FreeBSD boot
/dev/sda3    534528    4728831   4194304     2G FreeBSD swap
/dev/sda4   4728832 1000214527 995485696 474,7G FreeBSD ZFS

zpool list -v
Code:
└[~]> zpool list -v                 
NAME                                           SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
rpool                                          928G  62.2G   866G        -         -     0%     6%  1.00x    ONLINE  -
  nvme-WDS100T1X0E-00AFY0_2140JY447104-part2   931G  62.2G   866G        -         -     0%  6.70%      -    ONLINE
zroot                                          472G  2.73G   469G        -         -     0%     0%  1.00x    ONLINE  /mnt/var
  usb-HFM512GD_3JX013N_CNA5N81771120615Y-0:0   475G  2.73G   469G        -         -     0%  0.57%      -    ONLINE

zfs list
Code:
└[~]> zfs list -t filesystem       
NAME                    USED  AVAIL     REFER  MOUNTPOINT
rpool                  62.2G   837G       96K  none
rpool/arch             35.8G   837G       96K  none
rpool/arch/home        20.0G   837G     18.4G  legacy
rpool/arch/root        15.8G   837G     14.7G  /
rpool/condivise         276K   837G      116K  /condivise
rpool/tumbleweed       10.8G   837G       96K  none
rpool/tumbleweed/home   829M   837G      719M  legacy
rpool/tumbleweed/root  9.99G   837G     7.30G  /
rpool/void             15.6G   837G       96K  none
rpool/void/home        4.29G   837G     2.64G  legacy
rpool/void/root        11.3G   837G     9.24G  /
zroot                  2.73G   455G       96K  /mnt/var/zroot
zroot/ROOT             1.23G   455G       96K  none
zroot/ROOT/default     1.23G   455G     1.23G  /mnt/var
zroot/tmp               216K   455G      144K  /mnt/var/tmp
zroot/usr              1.50G   455G       96K  /mnt/var/usr
zroot/usr/home         12.9M   455G     12.8M  /mnt/var/usr/home
zroot/usr/ports         759M   455G      759M  /mnt/var/usr/ports
zroot/usr/src           760M   455G      760M  /mnt/var/usr/src
zroot/var               768K   455G       96K  /mnt/var/var
zroot/var/audit          96K   455G       96K  /mnt/var/var/audit
zroot/var/crash          96K   455G       96K  /mnt/var/var/crash
zroot/var/log           288K   455G      192K  /mnt/var/var/log
zroot/var/mail           96K   455G       96K  /mnt/var/var/mail
zroot/var/tmp            96K   455G       96K  /mnt/var/var/tmp
┌[zar_marco@arch-zfs] [/dev/pts/1]


I had try to create subvol for various dataset of freebsd and with send/receive I tried to move on nvme0n1p2, but after this shift I was unable to boot my linux distros. How can I do it?

I would like move freebsd because at the moment this is on external USB disk

The problem is also I must migrate efi partition as on freebsd is on fat16, on linux in fat32
 
Ok I've solved.
I had create snapshots and move in another pool with send/receive.
I had copy file from freebsd boot/efi to efi on fat32.
Setted bootfs in my new root pool, modified /boot/loader.conf with openzfs instead zfs and installed openzfs packages
 
Back
Top