Lakshmipathi / dduper

Fast block-level out-of-band BTRFS deduplication tool.
GNU General Public License v2.0
168 stars 18 forks source link

Operation not permitted on synology #16

Open segator opened 4 years ago

segator commented 4 years ago

Hi trying to run your amazing tool on a synology with BTRFS using your docker as described in install.md

but i'm seeing errors /dev/mapper/cachedev_0 is the dev that synology mounts the BTRFS(checked with the mount command) maybe is because synology have NVME caching

parent transid verify failed on 7939913383936 wanted 7154693 found 7154700
parent transid verify failed on 7939913383936 wanted 7154693 found 7154700
parent transid verify failed on 7939913383936 wanted 7154693 found 7154700
Ignoring transid failure
leaf parent key incorrect 7939913383936
ERROR: failed to read block groups: Operation not permitted
unable to open /dev/mapper/cachedev_0
Lakshmipathi commented 4 years ago

Thanks for the report. Could you please provide below details to understand the issue better.

  1. Are you trying to de-dupe the files? If so, what happens when you try something like --dry-run or --analyze which doesn't perform any write operation on the disks.
  2. Is this RAID setup?
  3. Is it possible to attach strace output?
    
    $ docker run -itd --device /dev/mapper/cachedev_0 -v /btrfs_mnt:/mnt laks/dduper
    $ docker exec -it <container-id> bash
    $ apt-get install strace 

run command which caused above permission issue with strace

$ strace -o /mnt/logs.txt dduper --device /dev/mapper/cachedev --dir /mnt --analyze

copy the logs.txt from btrfs-mount point

Lakshmipathi commented 4 years ago

Hi @segator , You had chance to explore this further?

Lakshmipathi commented 4 years ago

leaf parent key incorrect 7939913383936 ERROR: failed to read block groups: Operation not permitted

Google Search points above may be related BTRFS related issue. I'll go ahead mark this as closed. If you have more details, please re-open this issue. thank you!

Lakshmipathi commented 4 years ago

I think this issue may be related to BTRFS subvolume which has been reported by others too.

Lakshmipathi commented 4 years ago

Quick update on subvolume: I spent 3 or 4 days trying to figure out issue with sub-volume, I can dump csum of subvolume from different code path. Still need some work to explore the btrfs disk-layout.