Re: "Too many levels of symbolic links"

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

 



On Fri, 2014-02-28 at 08:29 -0500, Alexander Viro wrote:
> On Fri, Feb 28, 2014 at 01:12:58PM +0100, Donald Buczek wrote:
> 
> > Obviously, "cleared mounted on dentry" is missing.
> > 
> > It looks like we enter put_mountpoint() but don't get to
> > dentry->d_flags &= ~DCACHE_MOUNTED;
> > 
> > mp->m_count is not zero probably.
> > 
> > What does it mean? The mount is still locked but not in the mount hash?
> 
> No, it means that something else is mounted on the same dentry (in another
> part of mount tree, obviously).
> 
> If you mount the same fs on two different mountpoints, e.g.
> mount /dev/sda1 /mnt
> mount /dev/sda1 /tmp/foo
> you will have the same dentries seen in two places.  Now,
> mount /dev/sdb11 /mnt/a
> mount /dev/sdc5 /tmp/foo/a
> 
> and you've got two different filesystems mounted on two different places
> (/mnt/a and /tmp/foo/a).  These two places have different vfsmounts,
> but the same dentry.  struct mountpoint is associated with dentry, so
> it's also the same for both.  And it serves as a mountpoint for two
> vfsmounts - one for fs from sdb11, another for fs from sdc5.
> 
> Now umount /mnt/a; one of those two vfsmounts is gone now.  struct mountpoint
> survives, of course, and dentry is *still* a mountpoint.  sdc5 is still
> mounted on /tmp/foo/a, after all...

Ahh, right ... I'll need to think about my use (misuse) of
d_mountpoint().

Thanks Al.

--
To unsubscribe from this list: send the line "unsubscribe autofs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux Ext4]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux