lkml.org 
[lkml]   [2012]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] cgroup: fix to allow mounting a hierarchy by name
Hello,

On Fri, Jan 06, 2012 at 10:24:47AM +0800, Li Zefan wrote:
> There's a corner case where "mount --bind" can't be used:
>
> # mount -t cgroup -o none,name=hier1 xxx /mnt
> # mkdir /mnt/tmp
> # umount /mnt
>
> Since there's a sub-cgroup in it, umount won't destroy the hierarchy,
> but "hide" it, so the name=xxx is necessary to re-mount it.
>
> > Also, what's the use case for
> > mounting the same cgroup directory multiple times? Why is that
> > necessary? Is it useful for some namespace-savvy setup?
>
> I don't have a use case in real life. It was made so at the very
> beginning of cgroup, and we should't break it without strong reasons.
> We can mount other pseudo filesystems like procfs, sysfs and debugfs
> multiple times, right?

Yeah, we shouldn't break it so I applied the patch with a lot of
grumbling. This is something which shouldn't have existed at all. :(

Thanks a lot for the explanation and patience.

--
tejun


\
 
 \ /
  Last update: 2012-01-06 03:31    [W:0.057 / U:2.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site