]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
cgroup_namespaces.7: ffix
authorMichael Kerrisk <mtk.manpages@gmail.com>
Wed, 10 Jun 2020 10:04:48 +0000 (12:04 +0200)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Wed, 10 Jun 2020 10:04:48 +0000 (12:04 +0200)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man7/cgroup_namespaces.7

index 842e0b8d2daf823f8bdfb1adecd27bc4e7a413d4..773379aeb8f48f966abd0da4943d486d06449867 100644 (file)
@@ -102,11 +102,11 @@ Next, we use
 .BR unshare (1)
 to create a process running a new shell in new cgroup and mount namespaces:
 .PP
-.EX
 .in +4n
+.EX
 # \fBPS1="sh2# " unshare \-Cm bash\fP
-.in
 .EE
+.in
 .PP
 From the new shell started by
 .BR unshare (1),
@@ -118,16 +118,16 @@ a process that is in the initial cgroup namespace
 with PID 1), and the process in the sibling cgroup
 .RI ( sub2 ):
 .PP
-.EX
 .in +4n
+.EX
 sh2# \fBcat /proc/self/cgroup | grep freezer\fP
 7:freezer:/
 sh2# \fBcat /proc/1/cgroup | grep freezer\fP
 7:freezer:/..
 sh2# \fBcat /proc/20124/cgroup | grep freezer\fP
 7:freezer:/../sub2
-.in
 .EE
+.in
 .PP
 From the output of the first command,
 we see that the freezer cgroup membership of the new shell
@@ -147,12 +147,12 @@ However, when we look in
 .IR /proc/self/mountinfo
 we see the following anomaly:
 .PP
-.EX
 .in +4n
+.EX
 sh2# \fBcat /proc/self/mountinfo | grep freezer\fP
 155 145 0:32 /.. /sys/fs/cgroup/freezer ...
-.in
 .EE
+.in
 .PP
 The fourth field of this line
 .RI ( /.. )
@@ -169,16 +169,16 @@ To fix this problem, we must remount the freezer cgroup filesystem
 from the new shell (i.e., perform the mount from a process that is in the
 new cgroup namespace), after which we see the expected results:
 .PP
-.EX
 .in +4n
+.EX
 sh2# \fBmount \-\-make\-rslave /\fP     # Don't propagate mount events
                                # to other namespaces
 sh2# \fBumount /sys/fs/cgroup/freezer\fP
 sh2# \fBmount \-t cgroup \-o freezer freezer /sys/fs/cgroup/freezer\fP
 sh2# \fBcat /proc/self/mountinfo | grep freezer\fP
 155 145 0:32 / /sys/fs/cgroup/freezer rw,relatime ...
-.in
 .EE
+.in
 .\"
 .SH CONFORMING TO
 Namespaces are a Linux-specific feature.