1MOUNT.CIFS(8) System Administration tools MOUNT.CIFS(8)
2
3
4
6 mount.cifs - mount using the Common Internet File System (CIFS)
7
9 mount.cifs {service} {mount-point} [-o options]
10
12 This tool is part of the cifs-utils suite.
13
14 mount.cifs mounts a Linux CIFS filesystem. It is usually invoked
15 indirectly by the mount(8) command when using the "-t cifs" option.
16 This command only works in Linux, and the kernel must support the cifs
17 filesystem. The CIFS protocol is the successor to the SMB protocol and
18 is supported by most Windows servers and many other commercial servers
19 and Network Attached Storage appliances as well as by the popular Open
20 Source server Samba.
21
22 The mount.cifs utility attaches the UNC name (exported network
23 resource) specified as service (using //server/share syntax, where
24 "server" is the server name or IP address and "share" is the name of
25 the share) to the local directory mount-point.
26
27 Options to mount.cifs are specified as a comma-separated list of
28 key=value pairs. It is possible to send options other than those listed
29 here, assuming that the cifs filesystem kernel module (cifs.ko)
30 supports them. Unrecognized cifs mount options passed to the cifs vfs
31 kernel code will be logged to the kernel log.
32
33 mount.cifs causes the cifs vfs to launch a thread named cifsd. After
34 mounting it keeps running until the mounted resource is unmounted
35 (usually via the umount utility).
36
37 mount.cifs -V command displays the version of cifs mount helper.
38
39 modinfo cifs command displays the version of cifs module.
40
42 user=arg
43 specifies the username to connect as. If this is not given, then
44 the environment variable USER is used. This option can also take
45 the form "user%password" or "workgroup/user" or
46 "workgroup/user%password" to allow the password and workgroup to be
47 specified as part of the username.
48
49 Note
50 The cifs vfs accepts the parameter user=, or for users familiar
51 with smbfs it accepts the longer form of the parameter
52 username=. Similarly the longer smbfs style parameter names may
53 be accepted as synonyms for the shorter cifs parameters
54 pass=,dom= and cred=.
55
56 password=arg
57 specifies the CIFS password. If this option is not given then the
58 environment variable PASSWD is used. If the password is not
59 specified directly or indirectly via an argument to mount,
60 mount.cifs will prompt for a password, unless the guest option is
61 specified.
62
63 Note that a password which contains the delimiter character (i.e. a
64 comma ´,´) will fail to be parsed correctly on the command line.
65 However, the same password defined in the PASSWD environment
66 variable or via a credentials file (see below) or entered at the
67 password prompt will be read correctly.
68
69 credentials=filename
70 specifies a file that contains a username and/or password and
71 optionally the name of the workgroup. The format of the file is:
72
73 username=value
74 password=value
75 domain=value
76
77 This is preferred over having passwords in plaintext in a shared
78 file, such as /etc/fstab. Be sure to protect any credentials file
79 properly.
80
81 uid=arg
82 sets the uid that will own all files or directories on the mounted
83 filesystem when the server does not provide ownership information.
84 It may be specified as either a username or a numeric uid. When not
85 specified, the default is uid 0. The mount.cifs helper must be at
86 version 1.10 or higher to support specifying the uid in non-numeric
87 form. See the section on FILE AND DIRECTORY OWNERSHIP AND
88 PERMISSIONS below for more information.
89
90 forceuid
91 instructs the client to ignore any uid provided by the server for
92 files and directories and to always assign the owner to be the
93 value of the uid= option. See the section on FILE AND DIRECTORY
94 OWNERSHIP AND PERMISSIONS below for more information.
95
96 cruid=arg
97 sets the uid of the owner of the credentials cache. This is
98 primarily useful with sec=krb5. The default is the real uid of the
99 process performing the mount. Setting this parameter directs the
100 upcall to look for a credentials cache owned by that user.
101
102 gid=arg
103 sets the gid that will own all files or directories on the mounted
104 filesystem when the server does not provide ownership information.
105 It may be specified as either a groupname or a numeric gid. When
106 not specified, the default is gid 0. The mount.cifs helper must be
107 at version 1.10 or higher to support specifying the gid in
108 non-numeric form. See the section on FILE AND DIRECTORY OWNERSHIP
109 AND PERMISSIONS below for more information.
110
111 forcegid
112 instructs the client to ignore any gid provided by the server for
113 files and directories and to always assign the owner to be the
114 value of the gid= option. See the section on FILE AND DIRECTORY
115 OWNERSHIP AND PERMISSIONS below for more information.
116
117 port=arg
118 sets the port number on which the client will attempt to contact
119 the CIFS server. If this value is specified, look for an existing
120 connection with this port, and use that if one exists. If one
121 doesn't exist, try to create a new connection on that port. If that
122 connection fails, return an error. If this value isn't specified,
123 look for an existing connection on port 445 or 139. If no such
124 connection exists, try to connect on port 445 first and then port
125 139 if that fails. Return an error if both fail.
126
127 servernetbiosname=arg
128 Specify the server netbios name (RFC1001 name) to use when
129 attempting to setup a session to the server. Although rarely needed
130 for mounting to newer servers, this option is needed for mounting
131 to some older servers (such as OS/2 or Windows 98 and Windows ME)
132 since when connecting over port 139 they, unlike most newer
133 servers, do not support a default server name. A server name can be
134 up to 15 characters long and is usually uppercased.
135
136 servern=arg
137 Synonym for servernetbiosname.
138
139 netbiosname=arg
140 When mounting to servers via port 139, specifies the RFC1001 source
141 name to use to represent the client netbios machine name when doing
142 the RFC1001 netbios session initialize.
143
144 file_mode=arg
145 If the server does not support the CIFS Unix extensions this
146 overrides the default file mode.
147
148 dir_mode=arg
149 If the server does not support the CIFS Unix extensions this
150 overrides the default mode for directories.
151
152 ip=arg
153 sets the destination IP address. This option is set automatically
154 if the server name portion of the requested UNC name can be
155 resolved so rarely needs to be specified by the user.
156
157 domain=arg
158 sets the domain (workgroup) of the user
159
160 guest
161 don´t prompt for a password
162
163 iocharset
164 Charset used to convert local path names to and from Unicode.
165 Unicode is used by default for network path names if the server
166 supports it. If iocharset is not specified then the nls_default
167 specified during the local client kernel build will be used. If
168 server does not support Unicode, this parameter is unused.
169
170 ro
171 mount read-only
172
173 rw
174 mount read-write
175
176 setuids
177 If the CIFS Unix extensions are negotiated with the server the
178 client will attempt to set the effective uid and gid of the local
179 process on newly created files, directories, and devices (create,
180 mkdir, mknod). If the CIFS Unix Extensions are not negotiated, for
181 newly created files and directories instead of using the default
182 uid and gid specified on the the mount, cache the new file´s uid
183 and gid locally which means that the uid for the file can change
184 when the inode is reloaded (or the user remounts the share).
185
186 nosetuids
187 The client will not attempt to set the uid and gid on on newly
188 created files, directories, and devices (create, mkdir, mknod)
189 which will result in the server setting the uid and gid to the
190 default (usually the server uid of the user who mounted the share).
191 Letting the server (rather than the client) set the uid and gid is
192 the default.If the CIFS Unix Extensions are not negotiated then the
193 uid and gid for new files will appear to be the uid (gid) of the
194 mounter or the uid (gid) parameter specified on the mount.
195
196 perm
197 Client does permission checks (vfs_permission check of uid and gid
198 of the file against the mode and desired operation), Note that this
199 is in addition to the normal ACL check on the target machine done
200 by the server software. Client permission checking is enabled by
201 default.
202
203 noperm
204 Client does not do permission checks. This can expose files on this
205 mount to access by other users on the local client system. It is
206 typically only needed when the server supports the CIFS Unix
207 Extensions but the UIDs/GIDs on the client and server system do not
208 match closely enough to allow access by the user doing the mount.
209 Note that this does not affect the normal ACL check on the target
210 machine done by the server software (of the server ACL against the
211 user name provided at mount time).
212
213 dynperm
214 Instructs the server to maintain ownership and permissions in
215 memory that can´t be stored on the server. This information can
216 disappear at any time (whenever the inode is flushed from the
217 cache), so while this may help make some applications work, it´s
218 behavior is somewhat unreliable. See the section below on FILE AND
219 DIRECTORY OWNERSHIP AND PERMISSIONS for more information.
220
221 cache=
222 Cache mode. See the section below on CACHE COHERENCY for details.
223 Allowed values are:
224
225 · none: do not cache file data at all
226
227 · strict: follow the CIFS/SMB2 protocol strictly
228
229 · loose: allow loose caching semantics
230
231 The default in kernels prior to 3.7 was "loose". As of kernel 3.7
232 the default is "strict".
233
234 directio
235 Do not do inode data caching on files opened on this mount. This
236 precludes mmaping files on this mount. In some cases with fast
237 networks and little or no caching benefits on the client (e.g. when
238 the application is doing large sequential reads bigger than page
239 size without rereading the same data) this can provide better
240 performance than the default behavior which caches reads
241 (readahead) and writes (writebehind) through the local Linux client
242 pagecache if oplock (caching token) is granted and held. Note that
243 direct allows write operations larger than page size to be sent to
244 the server. On some kernels this requires the cifs.ko module to be
245 built with the CIFS_EXPERIMENTAL configure option.
246
247 This option is will be deprecated in 3.7. Users should use
248 cache=none instead on more recent kernels.
249
250 strictcache
251 Use for switching on strict cache mode. In this mode the client
252 reads from the cache all the time it has Oplock Level II, otherwise
253 - read from the server. As for write - the client stores a data in
254 the cache in Exclusive Oplock case, otherwise - write directly to
255 the server.
256
257 This option is will be deprecated in 3.7. Users should use
258 cache=strict instead on more recent kernels.
259
260 rwpidforward
261 Forward pid of a process who opened a file to any read or write
262 operation on that file. This prevent applications like WINE from
263 failing on read and write if we use mandatory brlock style.
264
265 mapchars
266 Translate six of the seven reserved characters (not backslash, but
267 including the colon, question mark, pipe, asterik, greater than and
268 less than characters) to the remap range (above 0xF000), which also
269 allows the CIFS client to recognize files created with such
270 characters by Windows´s POSIX emulation. This can also be useful
271 when mounting to most versions of Samba (which also forbids
272 creating and opening files whose names contain any of these seven
273 characters). This has no effect if the server does not support
274 Unicode on the wire. Please note that the files created with
275 mapchars mount option may not be accessible if the share is mounted
276 without that option.
277
278 nomapchars
279 Do not translate any of these seven characters (default)
280
281 intr
282 currently unimplemented
283
284 nointr
285 (default) currently unimplemented
286
287 hard
288 The program accessing a file on the cifs mounted file system will
289 hang when the server crashes.
290
291 soft
292 (default) The program accessing a file on the cifs mounted file
293 system will not hang when the server crashes and will return errors
294 to the user application.
295
296 noacl
297 Do not allow POSIX ACL operations even if server would support
298 them.
299
300 The CIFS client can get and set POSIX ACLs (getfacl, setfacl) to
301 Samba servers version 3.0.10 and later. Setting POSIX ACLs requires
302 enabling both CIFS_XATTR and then CIFS_POSIX support in the CIFS
303 configuration options when building the cifs module. POSIX ACL
304 support can be disabled on a per mount basis by specifying "noacl"
305 on mount.
306
307 cifsacl
308 This option is used to map CIFS/NTFS ACLs to/from Linux permission
309 bits, map SIDs to/from UIDs and GIDs, and get and set Security
310 Descriptors.
311
312 See sections on CIFS/NTFS ACL, SID/UID/GID MAPPING, SECURITY
313 DESCRIPTORS for more information.
314
315 backupuid=arg
316 Restrict access to files with the backup intent to a user. Either a
317 name or an id must be provided as an argument, there are no default
318 values.
319
320 See section ACCESSING FILES WITH BACKUP INTENT for more details
321
322 backupgid=arg
323 Restrict access to files with the backup intent to a group. Either
324 a name or an id must be provided as an argument, there are no
325 default values.
326
327 See section ACCESSING FILES WITH BACKUP INTENT for more details
328
329 nocase
330 Request case insensitive path name matching (case sensitive is the
331 default if the server suports it).
332
333 ignorecase
334 Synonym for nocase.
335
336 sec=
337 Security mode. Allowed values are:
338
339 · none attempt to connection as a null user (no name)
340
341 · krb5 Use Kerberos version 5 authentication
342
343 · krb5i Use Kerberos authentication and forcibly enable packet
344 signing
345
346 · ntlm Use NTLM password hashing (default)
347
348 · ntlmi Use NTLM password hashing and force packet signing
349
350 · ntlmv2 Use NTLMv2 password hashing
351
352 · ntlmv2i Use NTLMv2 password hashing and force packet signing
353
354 · ntlmssp Use NTLMv2 password hashing encapsulated in Raw NTLMSSP
355 message
356
357 · ntlmsspi Use NTLMv2 password hashing encapsulated in Raw
358 NTLMSSP message, and force packet signing
359
360 If the server requires signing during protocol negotiation, then it
361 may be enabled automatically. Packet signing may also be enabled
362 automatically if it's enabled in /proc/fs/cifs/SecurityFlags.
363
364 nobrl
365 Do not send byte range lock requests to the server. This is
366 necessary for certain applications that break with cifs style
367 mandatory byte range locks (and most cifs servers do not yet
368 support requesting advisory byte range locks).
369
370 sfu
371 When the CIFS Unix Extensions are not negotiated, attempt to create
372 device files and fifos in a format compatible with Services for
373 Unix (SFU). In addition retrieve bits 10-12 of the mode via the
374 SETFILEBITS extended attribute (as SFU does). In the future the
375 bottom 9 bits of the mode mode also will be emulated using queries
376 of the security descriptor (ACL). [NB: requires version 1.39 or
377 later of the CIFS VFS. To recognize symlinks and be able to create
378 symlinks in an SFU interoperable form requires version 1.40 or
379 later of the CIFS VFS kernel module.
380
381 serverino
382 Use inode numbers (unique persistent file identifiers) returned by
383 the server instead of automatically generating temporary inode
384 numbers on the client. Although server inode numbers make it easier
385 to spot hardlinked files (as they will have the same inode numbers)
386 and inode numbers may be persistent (which is userful for some
387 sofware), the server does not guarantee that the inode numbers are
388 unique if multiple server side mounts are exported under a single
389 share (since inode numbers on the servers might not be unique if
390 multiple filesystems are mounted under the same shared higher level
391 directory). Note that not all servers support returning server
392 inode numbers, although those that support the CIFS Unix
393 Extensions, and Windows 2000 and later servers typically do support
394 this (although not necessarily on every local server filesystem).
395 Parameter has no effect if the server lacks support for returning
396 inode numbers or equivalent. This behavior is enabled by default.
397
398 noserverino
399 Client generates inode numbers itself rather than using the actual
400 ones from the server.
401
402 See section INODE NUMBERS for more information.
403
404 nounix
405 Disable the CIFS Unix Extensions for this mount. This can be useful
406 in order to turn off multiple settings at once. This includes POSIX
407 acls, POSIX locks, POSIX paths, symlink support and retrieving
408 uids/gids/mode from the server. This can also be useful to work
409 around a bug in a server that supports Unix Extensions.
410
411 See section INODE NUMBERS for more information.
412
413 nouser_xattr
414 (default) Do not allow getfattr/setfattr to get/set xattrs, even if
415 server would support it otherwise.
416
417 rsize=arg
418 default network read size (usually 16K). The client currently can
419 not use rsize larger than CIFSMaxBufSize. CIFSMaxBufSize defaults
420 to 16K and may be changed (from 8K to the maximum kmalloc size
421 allowed by your kernel) at module install time for cifs.ko. Setting
422 CIFSMaxBufSize to a very large value will cause cifs to use more
423 memory and may reduce performance in some cases. To use rsize
424 greater than 127K (the original cifs protocol maximum) also
425 requires that the server support a new Unix Capability flag (for
426 very large read) which some newer servers (e.g. Samba 3.0.26 or
427 later) do. rsize can be set from a minimum of 2048 to a maximum of
428 130048 (127K or CIFSMaxBufSize, whichever is smaller)
429
430 wsize=bytes
431 Maximum amount of data that the kernel will send in a write request
432 in bytes. Prior to RHEL6.2 kernels, the default and maximum was
433 57344 (14 * 4096 pages). As of RHEL6.2, the default depends on
434 whether the client and server negotiate large writes via POSIX
435 extensions. If they do then the default is 1M, and the maximum
436 allowed is 16M. If they do not, then the default is 65536 and the
437 maximum allowed is 131007.
438
439 Note that this value is just a starting point for negotiation. The
440 client and server may negotiate this size downward according to the
441 server's capabilities.
442
443 fsc
444 Enable local disk caching using FS-Cache for CIFS. This option
445 could be useful to improve performance on a slow link, heavily
446 loaded server and/or network where reading from the disk is faster
447 than reading from the server (over the network). This could also
448 impact the scalability positively as the number of calls to the
449 server are reduced. But, be warned that local caching is not
450 suitable for all workloads, for e.g., read-once type workloads. So,
451 you need to consider carefully the situation/workload before using
452 this option. Currently, local disk caching is enabled for CIFS
453 files opened as read-only.
454
455 NOTE: This feature is available only in the recent kernels that
456 have been built with the kernel config option CONFIG_CIFS_FSCACHE.
457 You also need to have cachefilesd daemon installed and running to
458 make the cache operational.
459
460 multiuser
461 Map user accesses to individual credentials when accessing the
462 server. By default, CIFS mounts only use a single set of user
463 credentials (the mount credentials) when accessing a share. With
464 this option, the client instead creates a new session with the
465 server using the user's credentials whenever a new user accesses
466 the mount. Further accesses by that user will also use those
467 credentials. Because the kernel cannot prompt for passwords,
468 multiuser mounts are limited to mounts using sec= options that
469 don't require passwords.
470
471 With this change, it's feasible for the server to handle
472 permissions enforcement, so this option also implies "noperm".
473 Furthermore, when unix extensions aren't in use and the
474 administrator has not overriden ownership using the uid= or gid=
475 options, ownership of files is presented as the current user
476 accessing the share.
477
478 actimeo=arg
479 The time (in seconds) that the CIFS client caches attributes of a
480 file or directory before it requests attribute information from a
481 server. During this period the changes that occur on the server
482 remain undetected until the client checks the server again.
483
484 By default, the attribute cache timeout is set to 1 second. This
485 means more frequent on-the-wire calls to the server to check
486 whether attributes have changed which could impact performance.
487 With this option users can make a tradeoff between performance and
488 cache metadata correctness, depending on workload needs. Shorter
489 timeouts mean better cache coherency, but frequent increased number
490 of calls to the server. Longer timeouts mean a reduced number of
491 calls to the server but looser cache coherency. The actimeo value
492 is a positive integer that can hold values between 0 and a maximum
493 value of 2^30 * HZ (frequency of timer interrupt) setting.
494
495 noposixpaths
496 If unix extensions are enabled on a share, then the client will
497 typically allow filenames to include any character besides '/' in a
498 pathname component, and will use forward slashes as a pathname
499 delimiter. This option prevents the client from attempting to
500 negotiate the use of posix-style pathnames to the server.
501
502 posixpaths
503 Inverse of noposixpaths.
504
505 prefixpath=
506 It's possible to mount a subdirectory of a share. The preferred way
507 to do this is to append the path to the UNC when mounting. However,
508 it's also possible to do the same by setting this option and
509 providing the path there.
510
511 --verbose
512 Print additional debugging information for the mount. Note that
513 this parameter must be specified before the -o. For example:
514
515 mount -t cifs //server/share /mnt --verbose -o user=username
516
518 It´s generally preferred to use forward slashes (/) as a delimiter in
519 service names. They are considered to be the "universal delimiter"
520 since they are generally not allowed to be embedded within path
521 components on Windows machines and the client can convert them to
522 blackslashes (\) unconditionally. Conversely, backslash characters are
523 allowed by POSIX to be part of a path component, and can´t be
524 automatically converted in the same way.
525
526 mount.cifs will attempt to convert backslashes to forward slashes where
527 it´s able to do so, but it cannot do so in any path component following
528 the sharename.
529
531 When Unix Extensions are enabled, we use the actual inode number
532 provided by the server in response to the POSIX calls as an inode
533 number.
534
535 When Unix Extensions are disabled and "serverino" mount option is
536 enabled there is no way to get the server inode number. The client
537 typically maps the server-assigned "UniqueID" onto an inode number.
538
539 Note that the UniqueID is a different value from the server inode
540 number. The UniqueID value is unique over the scope of the entire
541 server and is often greater than 2 power 32. This value often makes
542 programs that are not compiled with LFS (Large File Support), to
543 trigger a glibc EOVERFLOW error as this won´t fit in the target
544 structure field. It is strongly recommended to compile your programs
545 with LFS support (i.e. with -D_FILE_OFFSET_BITS=64) to prevent this
546 problem. You can also use "noserverino" mount option to generate inode
547 numbers smaller than 2 power 32 on the client. But you may not be able
548 to detect hardlinks properly.
549
551 With a network filesystem such as CIFS or NFS, the client must contend
552 with the fact that activity on other clients or the server could change
553 the contents or attributes of a file without the client being aware of
554 it. One way to deal with such a problem is to mandate that all file
555 accesses go to the server directly. This is performance prohibitive
556 however, so most protocols have some mechanism to allow the client to
557 cache data locally.
558
559 The CIFS protocol mandates (in effect) that the client should not cache
560 file data unless it holds an opportunistic lock (aka oplock) or a
561 lease. Both of these entities allow the client to guarantee certain
562 types of exclusive access to a file so that it can access its contents
563 without needing to continually interact with the server. The server
564 will call back the client when it needs to revoke either of them and
565 allow the client a certain amount of time to flush any cached data.
566
567 The cifs client uses the kernel's pagecache to cache file data. Any I/O
568 that's done through the pagecache is generally page-aligned. This can
569 be problematic when combined with byte-range locks as Windows' locking
570 is mandatory and can block reads and writes from occurring.
571
572 cache=none means that the client never utilizes the cache for normal
573 reads and writes. It always accesses the server directly to satisfy a
574 read or write request.
575
576 cache=strict means that the client will attempt to follow the CIFS/SMB2
577 protocol strictly. That is, the cache is only trusted when the client
578 holds an oplock. When the client does not hold an oplock, then the
579 client bypasses the cache and accesses the server directly to satisfy a
580 read or write request. By doing this, the client avoids problems with
581 byte range locks. Additionally, byte range locks are cached on the
582 client when it holds an oplock and are "pushed" to the server when that
583 oplock is recalled.
584
585 cache=loose allows the client to use looser protocol semantics which
586 can sometimes provide better performance at the expense of cache
587 coherency. File access always involves the pagecache. When an oplock or
588 lease is not held, then the client will attempt to flush the cache soon
589 after a write to a file. Note that that flush does not necessarily
590 occur before a write system call returns.
591
592 In the case of a read without holding an oplock, the client will
593 attempt to periodically check the attributes of the file in order to
594 ascertain whether it has changed and the cache might no longer be
595 valid. This mechanism is much like the one that NFSv2/3 use for cache
596 coherency, but it particularly problematic with CIFS. Windows is quite
597 "lazy" with respect to updating the "LastWriteTime" field that the
598 client uses to verify this. The effect is that cache=loose can cause
599 data corruption when multiple readers and writers are working on the
600 same files.
601
602 Because of this, when multiple clients are accessing the same set of
603 files, then cache=strict is recommended. That helps eliminate problems
604 with cache coherency by following the CIFS/SMB2 protocols more
605 strictly.
606
607 Note too that no matter what caching model is used, the client will
608 always use the pagecache to handle mmap'ed files. Writes to mmap'ed
609 files are only guaranteed to be flushed to the server when msync() is
610 called, or on close().
611
612 The default in kernels prior to 3.7 was "loose". As of 3.7, the default
613 is "strict".
614
616 This option is used to work with file objects which posses Security
617 Descriptors and CIFS/NTFS ACL instead of UID, GID, file permission
618 bits, and POSIX ACL as user authentication model. This is the most
619 common authentication model for CIFS servers and is the one used by
620 Windows.
621
622 Support for this requires both CIFS_XATTR and CIFS_ACL support in the
623 CIFS configuration options when building the cifs module.
624
625 A CIFS/NTFS ACL is mapped to file permission bits using an algorithm
626 specified in the following Microsoft TechNet document:
627
628 · http://technet.microsoft.com/en-us/library/bb463216.aspx
629
630 Security descriptors for a file object can be retrieved and set
631 directly using extended attribute named system.cifs_acl. The security
632 descriptors presented via this interface are "raw" blobs of data and
633 need a userspace utility to either parse and format or to assemble it
634 such as getcifsacl(8) and setcifsacl(8) respectively.
635
636
637 Some of the things to consider while using this mount option:
638
639 · There may be an increased latency when handling metadata due to
640 additional requests to get and set security descriptors.
641
642 · The mapping between a CIFS/NTFS ACL and POSIX file permission bits
643 is imperfect and some ACL information may be lost in the
644 translation.
645
646 · While RHEL6 supports the mapping of permission bits to windows
647 ACLs, it does not map the owner SIDs to UID/GID or vice versa.
648
650 For an user on the server, desired access to a file is determined by
651 the permissions and rights associated with that file. This is
652 typically accomplished using owenrship and ACL. For a user who does
653 not have access rights to a file, it is still possible to access that
654 file for a specific or a targeted purpose by granting special rights.
655 One of the specific purposes is to access a file with the intent to
656 either backup or restore i.e. backup intent. The right to access a
657 file with the backup intent can typically be granted by making that
658 user a part of the built-in group Backup Operators. Thus, when this
659 user attempts to open a file with the backup intent, open request is
660 sent by setting the bit FILE_OPEN_FOR_BACKUP_INTENT as one of the
661 CreateOptions.
662
663 As an example, on a Windows server, a user named testuser, cannot open
664 this file with such a security descriptor.
665
666 REVISION:0x1
667 CONTROL:0x9404
668 OWNER:Administrator
669 GROUP:Domain Users
670 ACL:Administrator:ALLOWED/0x0/FULL
671
672 But the user testuser, if it becomes part of the group Backup
673 Operators, can open the file with the backup intent.
674
675 Any user on the client side who can authenticate as such a user on the
676 server, can access the files with the backup intent. But it is
677 desirable and preferable for security reasons amongst many, to restrict
678 this special right.
679
680 The mount option backupuid is used to restrict this special right to a
681 user which is specified by either a name or an id. The mount option
682 backupgid is used to restrict this special right to the users in a
683 group which is specified by either a name or an id. These two mount
684 options can be used together.
685
687 The core CIFS protocol does not provide unix ownership information or
688 mode for files and directories. Because of this, files and directories
689 will generally appear to be owned by whatever values the uid= or gid=
690 options are set, and will have permissions set to the default file_mode
691 and dir_mode for the mount. Attempting to change these values via
692 chmod/chown will return success but have no effect.
693
694 When the client and server negotiate unix extensions, files and
695 directories will be assigned the uid, gid, and mode provided by the
696 server. Because CIFS mounts are generally single-user, and the same
697 credentials are used no matter what user accesses the mount, newly
698 created files and directories will generally be given ownership
699 corresponding to whatever credentials were used to mount the share.
700
701 If the uid´s and gid´s being used do not match on the client and
702 server, the forceuid and forcegid options may be helpful. Note however,
703 that there is no corresponding option to override the mode. Permissions
704 assigned to a file when forceuid or forcegid are in effect may not
705 reflect the the real permissions.
706
707 When unix extensions are not negotiated, it´s also possible to emulate
708 them locally on the server using the "dynperm" mount option. When this
709 mount option is in effect, newly created files and directories will
710 receive what appear to be proper permissions. These permissions are not
711 stored on the server however and can disappear at any time in the
712 future (subject to the whims of the kernel flushing out the inode
713 cache). In general, this mount option is discouraged.
714
715 It´s also possible to override permission checking on the client
716 altogether via the noperm option. Server-side permission checks cannot
717 be overriden. The permission checks done by the server will always
718 correspond to the credentials used to mount the share, and not
719 necessarily to the user who is accessing the share.
720
722 The variable USER may contain the username of the person to be used to
723 authenticate to the server. The variable can be used to set both
724 username and password by using the format username%password.
725
726 The variable PASSWD may contain the password of the person using the
727 client.
728
729 The variable PASSWD_FILE may contain the pathname of a file to read the
730 password from. A single line of input is read and used as the password.
731
733 This command may be used only by root, unless installed setuid, in
734 which case the noeexec and nosuid mount flags are enabled. When
735 installed as a setuid program, the program follows the conventions set
736 forth by the mount program for user mounts, with the added restriction
737 that users must be able to chdir() into the mountpoint prior to the
738 mount in order to be able to mount onto it.
739
740 Some samba client tools like smbclient(8) honour client-side
741 configuration parameters present in smb.conf. Unlike those client
742 tools, mount.cifs ignores smb.conf completely.
743
745 The primary mechanism for making configuration changes and for reading
746 debug information for the cifs vfs is via the Linux /proc filesystem.
747 In the directory /proc/fs/cifs are various configuration files and
748 pseudo files which can display debug information. There are additional
749 startup options such as maximum buffer size and number of buffers which
750 only may be set when the kernel cifs vfs (cifs.ko module) is loaded.
751 These can be seen by running the modinfo utility against the file
752 cifs.ko which will list the options that may be passed to cifs during
753 module installation (device driver load). For more information see the
754 kernel file fs/cifs/README.
755
757 Mounting using the CIFS URL specification is currently not supported.
758
759 The credentials file does not handle usernames or passwords with
760 leading space.
761
762 Note that the typical response to a bug report is a suggestion to try
763 the latest version first. So please try doing that first, and always
764 include which versions you use of relevant software when reporting bugs
765 (minimum: mount.cifs (try mount.cifs -V), kernel (see /proc/version)
766 and server type you are trying to contact.
767
769 This man page is correct for version 1.74 of the cifs vfs filesystem
770 (roughly Linux kernel 3.0).
771
773 Documentation/filesystems/cifs.txt and fs/cifs/README in the linux
774 kernel source tree may contain additional options and information.
775
776 cifs.upcall(8)
777
779 Steve French
780
781 The syntax and manpage were loosely based on that of smbmount. It was
782 converted to Docbook/XML by Jelmer Vernooij.
783
784 The maintainer of the Linux cifs vfs and the userspace tool mount.cifs
785 is Steve French. The Linux CIFS Mailing list is the preferred place to
786 ask questions regarding these programs.
787
788
789
790cifs-utils 02/07/2010 MOUNT.CIFS(8)