]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
mount: add hint that context= has to be quoted
authorKarel Zak <kzak@redhat.com>
Tue, 10 Jan 2012 14:43:56 +0000 (15:43 +0100)
committerKarel Zak <kzak@redhat.com>
Tue, 10 Jan 2012 14:43:56 +0000 (15:43 +0100)
Addresses: http://bugzilla.redhat.com/show_bug.cgi?id=747038
Signed-off-by: Karel Zak <kzak@redhat.com>
mount/mount.8

index 2c4f6364fbae7756a932a3e199448d73eb71da5c..00b512e5ba9ce0fc4209a0bcb88c41663b4f436d 100644 (file)
@@ -839,7 +839,7 @@ xattrs are supported, you can save time not having to label every file by
 assigning the entire disk one security context.
 
 A commonly used option for removable media is
-.BR context=system_u:object_r:removable_t .
+.BR context="system_u:object_r:removable_t" .
 
 Two other options are
 .BR fscontext=
@@ -875,8 +875,23 @@ useful for things like stateless linux.
 Note that kernel rejects any remount request that includes the context
 option even if unchanged from the current context.
 
+.B Warning that \fIcontext\fP value might contains comma
+and in this case the value has to be properly quoted otherwise
+.BR mount (8)
+will interpret the comma as separator between mount options. Don't forget that
+shell strips off quotes and
+.BR "double quoting is required" ,
+for example:
+.RS
+.RS
+.sp
+mount -t tmpfs none /mnt \-o 'context="system_u:object_r:tmp_t:s0:c127,c456",noexec'
+.sp
+.RE
+
 For more details, see
 .BR selinux (8)
+.RE
 
 .TP
 .B defaults