Re: How to unmount mounts corresponding to super_block structure?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 26, 2013 at 11:19:30PM -0800, Anatol Pomozov wrote:
> Hi
> 
> On Tue, Feb 26, 2013 at 10:56 PM, Al Viro <viro@xxxxxxxxxxxxxxxxxx> wrote:
> > Simple: don't.  This is fundamentally wrong thing to do.  Not to mention
> > anything else, there may be more than one namespace out there.  This
> > operation makes no sense.
> 
> Yes I understand that there can be multiple namespaces. And I am fine
> with unmounting only in the current namespace. It is actually how
> libfuse currently implemented - it calls umount() on the mount point
> path, so it leaves 1) bind mounts 2) mounts in other namespaces
> untouched.
>
> Another ugly-but-working solution for fuse would be pass mountpoint
> path as a mount option and store it to super_block. Then in
> fuse_dev_release() call sys_umount().

Observe mount --move...  There is no promise that it'll stay mounted where
it used to be.  BTW, what about somebody having cloned the entire namespace?
Or spread the sucker via shared subtree stuff to another namespace, later
remounted private, etc.

"All places where the filesystem is mounted" is about as good a notion as
"all pathnames of a file".  Sorry.

	Besides, I _really_ doubt that it's a sane idea to start with; consider
something like mount --bind empty_directory <something I really want overmounted
and not accessible>.  Having it suddenly exposed without your explicit action
is not a good thing.  As the matter of fact, something very similar had been
outright NAKed by Linus and I agree with his arguments...
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux