-
Notifications
You must be signed in to change notification settings - Fork 84
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
Cannot use one of the lower directories as mount target #344
Comments
does it get unstuck if you kill the fuse-overlayfs process? The use case you have described is not supported since the lower dirs are supposed to be immutable (the same limitation exists for native overlay) otherwise the behavior is undefined. |
I think you misunderstood, I did not mean for the lower directories to be mutated while the file system is mounted. The idea is to add mods (either manually or through a script) to a list, then when the game is started all the different directories are stacked into a file system that is mounteded for the duration of the game. Once the game process terminates the file system is unmounted again so the user can add or remove mods again. The game does not write to the file system, these files are read-only to the game.
Sort of, but now when I try
|
you'd need to do an unmount there as well.
I thought you wanted to use one of the lower layers as the target for mount. Unless the mount is going to be read-only that causes the lower layer to also be mutated. I think it will be difficult anyway to support this scenario. There are cases where we cannot use *at syscalls, so we need to use the full path for file operations. So if you use a lower layer as the mount target, fuse-overlayfs itself will end up requesting files that are on the fuse-overlayfs mount itself. |
I think the in-kernel overlayfs support this use case. And this pattern actually happens a lot within |
Yes, that gets the directories unstuck. So my understanding is that this cannot be done with fuse-overlay, but only through regular FUSE with root access. Right? |
no, the suggestion I gave was to correctly unmount the FUSE file system |
I can only unmount ( The question is, can my original use-case be supported in fuse-overlayfs? If not then we can close this issue. |
The same issue seems to happen if you use a parent of the lowerdir as a target. I believe this should be fixable by using mount namespaces, but that may require using two processes. |
hi, edits: with the 1.10 release it seems to be fixed |
As a user of
fuse-overlayfs
I would like to use one of the lower directories as the mount target. This allows me to trick applications which search one hard-coded directory into searching multiple directories. A lot of games are programmed such that the user is expected to drop extra data files (e.g. mods) into one common directory; removing one mod is near impossible, especially if one mod overwrites files from another. A layered file system allows me to keep mods separate while tricking the application into thinking that they have all been mushed together.To replicate the issue create two directories
a
andb
. Then mount a layered file system:Don't actually try this, it will run into what feels like some sort of infinite loop. Unmounting
a
is impossible, FUSE will claim that the resource is busy. The only way I found to get rid of the mount was to reboot the machine.In this example
a
represents the expected directory andb
the custom one whose contents are to be spliced intoa
.a
might contain some files of its own, so it is important to be included in the list. A workaround is to first renamea
to_a
or something else, then create a new directorya
and mount everything as-o lower=_a:b a
.I don't know if this is a real bug or a limitation of FUSE.
The text was updated successfully, but these errors were encountered: