From 69b6b231d7e1a39f749a4a7fe11c118a7030a76f Mon Sep 17 00:00:00 2001 From: "Eric W. Biederman" Date: Thu, 11 Sep 2014 06:52:05 -0700 Subject: [PATCH] mount.2: Clarify use of 'mountflags' and 'data' for MS_REMOUNT Quoting Eric Biederman: One thing that has come up recently (in 3 separate implementations) is that mount(MS_REMOUNT|...,...) must include all of the mount flags that need to be preserved. People creating read-only bind mounts tend to miss that and the locked flags in mount namespaces. That issue was flushed out now that the kernel is now not allowing most mount flags to be cleared in mount namespaces. The interface is non-intuitive and we should at least document the weirdness. Signed-off-by: Michael Kerrisk --- man2/mount.2 | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/man2/mount.2 b/man2/mount.2 index 84efdae3c..bf341aa75 100644 --- a/man2/mount.2 +++ b/man2/mount.2 @@ -241,6 +241,13 @@ call; and .I filesystemtype are ignored. +The +.I mountflags +and +.I data +arguments should match the values used in the original +.BR mount () +call, except for those parameters that are being deliberately changed. The following .I mountflags