Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for btrfs stream files #9

Closed
kyak opened this issue Mar 31, 2023 · 3 comments
Closed

Support for btrfs stream files #9

kyak opened this issue Mar 31, 2023 · 3 comments

Comments

@kyak
Copy link

kyak commented Mar 31, 2023

Hi,

Thanks for this project!

btrfs-fuse works fine with BTRFS filesystem images. However, what I have is a "BTRFS stream file" (from btrfs send).

What I usually do is create BTRFS filesystem as a file, mount this file (as root) and do btrfs receive (as root) from BTRFS stream file.

What I try to do now with btrfs-fuse is I mount BTRFS filesystem file using FUSE, but I still have to be root to do btrfs receive, since mount point is owned by root.

Would it be possible to support mounting BTRFS stream files directly?

@adam900710
Copy link
Owner

Unfortunately btrfs-send stream is not following btrfs on-disk format.

Furthermore, such stream can be incremental, meaning without the source subvolume, we can not build the destination subvolume.

So in short, it's impossible to support btrfs-send stream in this project.

@kyak
Copy link
Author

kyak commented Apr 2, 2023

Thanks for you answer.

Do you know why I cannot specify user ownership on the mount point (it always belongs to root)?

I do this:

btrfs-fuse -o uid=1000 btrfs-image-file.img mount_dir

It says: ERROR: failed to scan device uid=1000: -2

I think if I were able to specify uid for the mountpoint, then btrfs receive without root would work.

@adam900710
Copy link
Owner

-o option is not supported thus it treats "uid=1000" as a file name.

btrfs receive won't work, because this project only implements a read-only FUSE.
btrfs receive needs to write which is not supported.

@kyak kyak closed this as completed Apr 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants