Linux Manual Pages development
 help / color / mirror / Atom feed
* [PATCH] man/man7/mount_namespaces.7: Fix an incorrect path in an example
@ 2025-02-16 18:59 Göran Uddeborg
  2025-02-16 20:03 ` Alejandro Colomar
  0 siblings, 1 reply; 3+ messages in thread
From: Göran Uddeborg @ 2025-02-16 18:59 UTC (permalink / raw)
  To: Alejandro Colomar; +Cc: linux-man

[-- Attachment #1: Type: text/plain, Size: 1034 bytes --]

In the example showing how locked mounts in a less privileged mount
namespace can not be split, first /etc/shadow is bind mounted, then an
attempt is done to unmount /mnt/dir, which gives an error complaining
that /etc/shadow is not mounted. The unmount should also refer to
/etc/shadow.

Signed-off-by: Göran Uddeborg <goeran@uddeborg.se>
---
 man/man7/mount_namespaces.7 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/man/man7/mount_namespaces.7 b/man/man7/mount_namespaces.7
index a1645e9e2..0e1223f99 100644
--- a/man/man7/mount_namespaces.7
+++ b/man/man7/mount_namespaces.7
@@ -1128,7 +1128,7 @@ .SS Restrictions on mount namespaces
 .EX
 # \fBunshare \-\-user \-\-map\-root\-user \-\-mount \[rs]\fP
                \fBstrace \-o /tmp/log \[rs]\fP
-               \fBumount /mnt/dir\fP
+               \fBumount /etc/shadow\fP
 umount: /etc/shadow: not mounted.
 # \fBgrep \[aq]\[ha]umount\[aq] /tmp/log\fP
 umount2("/etc/shadow", 0)     = \-1 EINVAL (Invalid argument)
-- 
2.40.1

[-- Attachment #2: Type: application/pgp-signature, Size: 862 bytes --]

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-02-16 21:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-16 18:59 [PATCH] man/man7/mount_namespaces.7: Fix an incorrect path in an example Göran Uddeborg
2025-02-16 20:03 ` Alejandro Colomar
2025-02-16 21:49   ` Göran Uddeborg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox