Bug 83741
Summary: | Regression: "btrfs send" does not work if the subvol is part of / | ||
---|---|---|---|
Product: | File System | Reporter: | Jan Steffens (jan.steffens) |
Component: | btrfs | Assignee: | Josef Bacik (josef) |
Status: | RESOLVED PATCH_ALREADY_AVAILABLE | ||
Severity: | normal | CC: | llowrey, osandov, teemow, wicke |
Priority: | P1 | ||
Hardware: | All | ||
OS: | Linux | ||
Kernel Version: | 3.16.1 | Subsystem: | |
Regression: | No | Bisected commit-id: | |
Attachments: | /proc/self/mounts |
Description
Jan Steffens
2014-09-02 09:20:49 UTC
Created attachment 149051 [details]
/proc/self/mounts
Maybe /proc/self/mounts needs to be checked in reverse, taking the first prefix that matches? If I have a btrfs at /mnt/data, then mount a tmpfs at /mnt and create the directory /mnt/data, "btrfs send /mnt/data" will attempt to send that path and make an inappropriate ioctl. I have encountered this in a slightly different way. I have create a snapshot of the root for backup purpose. I am getting the following: # btrfs sub sh /snapshot ERROR: /snapshot doesn't belong to btrfs mount point Snapshots for other btrfs filesystems on the same machine work just fine so it's only root snapshots that are affected. Here's an excerpt of my /proc/self/mounts: # grep -E '\W/\W|Root' /proc/self/mounts rootfs / rootfs rw 0 0 /dev/mapper/Cached-Root / btrfs rw,relatime,ssd,space_cache 0 0 /dev/mapper/Cached-Root /root/backup/mnt btrfs rw,relatime,ssd,space_cache 0 0 I'm running: btrfs-progs-3.16-1.fc20.x86_64 kernel-3.15.10-201.fc20.x86_64 I have nearly the same situation with a root btrfs and docker. $ grep dm-0 /proc/self/mounts /dev/dm-0 / btrfs rw,noatime,ssd,discard,space_cache 0 0 /dev/dm-0 /var/lib/docker/btrfs btrfs rw,noatime,ssd,discard,space_cache 0 0 The subvolumes below the docker tree work fine, but within root I get the same error. $ btrfs subvolume show / ERROR: / doesn't belong to btrfs mount point $ uname -r 3.16.2-1-ARCH $ btrfs --version Btrfs v3.16 There's currently a patch out for this: https://patchwork.kernel.org/patch/4842201/ |