lkml.org 
[lkml]   [2007]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] Fix d_path for lazy unmounts
Date
On Monday 05 February 2007 00:32, Andreas Gruenbacher wrote:
> Here is an updated patch that also catches this special case.
> [...]

The d_path change was to not start unreachable paths with slashes. In the
extreme case, this leads to an empty string. As it turns out, we are
reporting meaningless paths to users in a bunch of places in /proc, like
in /proc/$pid/mounts, where we ended up with entries like this:

rootfs rootfs rw 0 0

No wonder this immediately broke things; sorry for that.

Mountpoints are reported relative to the chroot if they are reachable from the
chroot, and relative to the namespace they are defined in otherwise. This is
big nonsense, but it's unclear to me how to best fix it:

- don't report unreachable mount points,
- somehow indicate which mountpoints are reachable and which are not,
like by prepending a question flag?

What's the point in reporting the rootfs at all -- it's never reachable to an
ordinary process?

The same issue shows up in a few other places as well: /proc/$pid/mountstats
which is similar to /proc/$pid/mounts, and here:

/proc/$pid/maps
/proc/$pid/smaps
/proc/$pid/numa_maps
/proc/swaps
/proc/mdstat
/proc/net/rpc/nfsd.fh/content
/proc/net/rpc/nfsd.export/content

We surely do not want to hide the entries that have unreachable pathnames
here...

Thanks,
Andreas
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-02-14 09:23    [W:0.073 / U:0.896 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site