Thomas-Tsai / partclone

Partclone provides utilities to backup a partition smartly and it is designed for higher compatibility of the file system by using existing library.
GNU General Public License v2.0
328 stars 108 forks source link

partclone.btrfs, btrfs-progs outdated causing failures #149

Open siyia2 opened 4 years ago

siyia2 commented 4 years ago

Hello, when trying to clone a btrfs partition with zstd transparent compression enabled, partclone fails with unsupported features error (10). Patclone btrfs failure log says it uses btrfs-progs=4.2.2 which is a very old version, current version is 5.7. I think at least version 5.1+ is needed to clone a btrfs partition with zstd enabled on disk.

trochdewei commented 4 years ago

I have same problem

siyia2 commented 4 years ago

Resolved in latest git code

trochdewei commented 4 years ago

@siyia2 did you try to restore created image? I had to run btrfs rescue chunk-recover on btrfs partition to be able to boot. Also i found that progress bar/estimate time broken when cloning/restoring

siyia2 commented 4 years ago

no i didnt try to restore, just cloned it and checked it by clonezilla

boretom commented 4 years ago

@trochdewei

trochdewei commented 4 years ago

@boretom Here is the content of /etc/fstab

UUID=A02D-FA34                              /boot/efi     vfat    umask=0077                                                                            0 2 
UUID=f990e578-aefa-4509-9262-030805325639   swap          swap    noatime                                                                               0 2 
UUID=8a21a9af-c7cd-4cc2-b243-486dda822afc   /mnt/pool     btrfs   noatime,space_cache,ssd,compress=zstd,commit=120,discard=async                        0 2 
UUID=8a21a9af-c7cd-4cc2-b243-486dda822afc   /             btrfs   subvol=@,noatime,space_cache,ssd,compress=zstd,commit=120,discard=async               0 1 
UUID=8a21a9af-c7cd-4cc2-b243-486dda822afc   /home         btrfs   subvol=@home,noatime,space_cache,ssd,compress=zstd,commit=120,discard=async           0 2 
UUID=8a21a9af-c7cd-4cc2-b243-486dda822afc   /.snapshots   btrfs   subvol=@snapshots,noatime,space_cache,ssd,compress=zstd,commit=120,discard=async      0 2 
UUID=8a21a9af-c7cd-4cc2-b243-486dda822afc   /var          btrfs   subvol=@var,noatime,space_cache,ssd,compress=zstd,commit=120,discard=async  0 2

and list of subvolumes on disk

# btrfs subvolume list -t -a /
ID      gen     top level       path
--      ---     ---------       ----
256     129455  5               <FS_TREE>/@
257     129458  5               <FS_TREE>/@home
279     129439  257             <FS_TREE>/@home/.snapshots
415     129455  5               <FS_TREE>/@snapshots
452     129458  5               <FS_TREE>/@var
1086    68524   415             <FS_TREE>/@snapshots/87/snapshot
2610    121468  415             <FS_TREE>/@snapshots/573/snapshot
2667    124493  415             <FS_TREE>/@snapshots/622/snapshot
2701    126498  415             <FS_TREE>/@snapshots/root.20201031T1956
2703    126509  415             <FS_TREE>/@snapshots/home.20201031T2010
2754    127862  415             <FS_TREE>/@snapshots/677/snapshot
2764    128248  415             <FS_TREE>/@snapshots/687/snapshot
2798    128782  415             <FS_TREE>/@snapshots/697/snapshot
2804    129070  415             <FS_TREE>/@snapshots/702/snapshot
2805    129083  415             <FS_TREE>/@snapshots/703/snapshot
2806    129092  415             <FS_TREE>/@snapshots/704/snapshot
2807    129177  415             <FS_TREE>/@snapshots/705/snapshot
2808    129202  415             <FS_TREE>/@snapshots/706/snapshot
2809    129309  415             <FS_TREE>/@snapshots/707/snapshot
2813    129344  415             <FS_TREE>/@snapshots/708/snapshot
2814    129419  415             <FS_TREE>/@snapshots/709/snapshot
2815    129452  415             <FS_TREE>/@snapshots/710/snapshot
boretom commented 3 years ago

@trochdewei : That does look ok to me, nothing out of the ordinary with your btrfs configuration.

If you got the time and space I'd try creating a backup not using partclone but using "only dd" in "Expert" mode (with compression of course). And do a restore from that to be able to narrow it down to if it's a btrfs partition issue that doesn't show up in day-to-day operation or an issue with partclone.btrfs.