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

Multiple mounts over a single filesystem (on a single block object) #712

Open
tbzatek opened this issue Dec 2, 2019 · 0 comments
Open
Projects

Comments

@tbzatek
Copy link
Member

tbzatek commented Dec 2, 2019

(Note: created as a result of my attempt to call bd_fs_unmount() over a block device path instead of a mount point path)

The org.freedesktop.UDisks2.Filesystem interface contains a MountPoints property - an array of paths/mount points this block device is mounted on. This properly reflects the state where filesystem can be mounted multiple times, either natively (for filesystems that supports multiple mounts) or by bind mounting.
(TODO: check rbind and --make-slave, --make-private, --make-unbindable mount options)

Question: let's have a filesystem that supports mounting subvolumes/snapshots via mount options - would that create a new block device or would we stack it all on a single block object? Hints: btrfs, zfs, stratis?! ...

The org.freedesktop.UDisks2.Filesystem.Unmount() method takes no specific mount point argument and as long as it's attached to a particular block device, it makes sense to unmount all mounts listed in the MountPoints property. For unmounting a specifc mount point we should either think about extending the options argument of the Unmount() method or adding a new method call.

For multiple mounts support I guess we also need to extend UDisksState matching as well.

edit: Don't make me start on supporting mount namespaces...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
btrfs
To do
Development

No branches or pull requests

1 participant