diff options
author | Steve French <smfrench@gmail.com> | 2017-09-14 15:51:20 -0400 |
---|---|---|
committer | Steve French <smfrench@gmail.com> | 2017-09-17 11:48:00 -0400 |
commit | ec11653b531099ddc08a8c7eb495ab83cae84e19 (patch) | |
tree | e336459108cd0bf4d69b9f6e721de0b1fb163fd1 /Documentation/filesystems | |
parent | bf2afee14e07de16d3cafc67edbfc2a3cc65e4bc (diff) |
CIFS/SMB3: Update documentation to reflect SMB3 and various changes
Signed-off-by: Steve French <smfrench@gmail.com>
Reviewed-by: Aurelien Aptel <aaptel@suse.com>
Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
Diffstat (limited to 'Documentation/filesystems')
-rw-r--r-- | Documentation/filesystems/cifs/AUTHORS | 5 | ||||
-rw-r--r-- | Documentation/filesystems/cifs/README | 81 | ||||
-rw-r--r-- | Documentation/filesystems/cifs/TODO | 72 | ||||
-rw-r--r-- | Documentation/filesystems/cifs/cifs.txt | 24 |
4 files changed, 91 insertions, 91 deletions
diff --git a/Documentation/filesystems/cifs/AUTHORS b/Documentation/filesystems/cifs/AUTHORS index c98800df677f..9f4f87e16240 100644 --- a/Documentation/filesystems/cifs/AUTHORS +++ b/Documentation/filesystems/cifs/AUTHORS | |||
@@ -41,6 +41,11 @@ Igor Mammedov (DFS support) | |||
41 | Jeff Layton (many, many fixes, as well as great work on the cifs Kerberos code) | 41 | Jeff Layton (many, many fixes, as well as great work on the cifs Kerberos code) |
42 | Scott Lovenberg | 42 | Scott Lovenberg |
43 | Pavel Shilovsky (for great work adding SMB2 support, and various SMB3 features) | 43 | Pavel Shilovsky (for great work adding SMB2 support, and various SMB3 features) |
44 | Aurelien Aptel (for DFS SMB3 work and some key bug fixes) | ||
45 | Ronnie Sahlberg (for SMB3 xattr work and bug fixes) | ||
46 | Shirish Pargaonkar (for many ACL patches over the years) | ||
47 | Sachin Prabhu (many bug fixes, including for reconnect, copy offload and security) | ||
48 | |||
44 | 49 | ||
45 | Test case and Bug Report contributors | 50 | Test case and Bug Report contributors |
46 | ------------------------------------- | 51 | ------------------------------------- |
diff --git a/Documentation/filesystems/cifs/README b/Documentation/filesystems/cifs/README index a54788405429..a9da51553ba3 100644 --- a/Documentation/filesystems/cifs/README +++ b/Documentation/filesystems/cifs/README | |||
@@ -1,10 +1,14 @@ | |||
1 | The CIFS VFS support for Linux supports many advanced network filesystem | 1 | This module supports the SMB3 family of advanced network protocols (as well |
2 | features such as hierarchical dfs like namespace, hardlinks, locking and more. | 2 | as older dialects, originally called "CIFS" or SMB1). |
3 | |||
4 | The CIFS VFS module for Linux supports many advanced network filesystem | ||
5 | features such as hierarchical DFS like namespace, hardlinks, locking and more. | ||
3 | It was designed to comply with the SNIA CIFS Technical Reference (which | 6 | It was designed to comply with the SNIA CIFS Technical Reference (which |
4 | supersedes the 1992 X/Open SMB Standard) as well as to perform best practice | 7 | supersedes the 1992 X/Open SMB Standard) as well as to perform best practice |
5 | practical interoperability with Windows 2000, Windows XP, Samba and equivalent | 8 | practical interoperability with Windows 2000, Windows XP, Samba and equivalent |
6 | servers. This code was developed in participation with the Protocol Freedom | 9 | servers. This code was developed in participation with the Protocol Freedom |
7 | Information Foundation. | 10 | Information Foundation. CIFS and now SMB3 has now become a defacto |
11 | standard for interoperating between Macs and Windows and major NAS appliances. | ||
8 | 12 | ||
9 | Please see | 13 | Please see |
10 | http://protocolfreedom.org/ and | 14 | http://protocolfreedom.org/ and |
@@ -15,30 +19,11 @@ for more details. | |||
15 | For questions or bug reports please contact: | 19 | For questions or bug reports please contact: |
16 | sfrench@samba.org (sfrench@us.ibm.com) | 20 | sfrench@samba.org (sfrench@us.ibm.com) |
17 | 21 | ||
22 | See the project page at: https://wiki.samba.org/index.php/LinuxCIFS_utils | ||
23 | |||
18 | Build instructions: | 24 | Build instructions: |
19 | ================== | 25 | ================== |
20 | For Linux 2.4: | 26 | For Linux: |
21 | 1) Get the kernel source (e.g.from http://www.kernel.org) | ||
22 | and download the cifs vfs source (see the project page | ||
23 | at http://us1.samba.org/samba/Linux_CIFS_client.html) | ||
24 | and change directory into the top of the kernel directory | ||
25 | then patch the kernel (e.g. "patch -p1 < cifs_24.patch") | ||
26 | to add the cifs vfs to your kernel configure options if | ||
27 | it has not already been added (e.g. current SuSE and UL | ||
28 | users do not need to apply the cifs_24.patch since the cifs vfs is | ||
29 | already in the kernel configure menu) and then | ||
30 | mkdir linux/fs/cifs and then copy the current cifs vfs files from | ||
31 | the cifs download to your kernel build directory e.g. | ||
32 | |||
33 | cp <cifs_download_dir>/fs/cifs/* to <kernel_download_dir>/fs/cifs | ||
34 | |||
35 | 2) make menuconfig (or make xconfig) | ||
36 | 3) select cifs from within the network filesystem choices | ||
37 | 4) save and exit | ||
38 | 5) make dep | ||
39 | 6) make modules (or "make" if CIFS VFS not to be built as a module) | ||
40 | |||
41 | For Linux 2.6: | ||
42 | 1) Download the kernel (e.g. from http://www.kernel.org) | 27 | 1) Download the kernel (e.g. from http://www.kernel.org) |
43 | and change directory into the top of the kernel directory tree | 28 | and change directory into the top of the kernel directory tree |
44 | (e.g. /usr/src/linux-2.5.73) | 29 | (e.g. /usr/src/linux-2.5.73) |
@@ -61,16 +46,13 @@ would simply type "make install"). | |||
61 | If you do not have the utility mount.cifs (in the Samba 3.0 source tree and on | 46 | If you do not have the utility mount.cifs (in the Samba 3.0 source tree and on |
62 | the CIFS VFS web site) copy it to the same directory in which mount.smbfs and | 47 | the CIFS VFS web site) copy it to the same directory in which mount.smbfs and |
63 | similar files reside (usually /sbin). Although the helper software is not | 48 | similar files reside (usually /sbin). Although the helper software is not |
64 | required, mount.cifs is recommended. Eventually the Samba 3.0 utility program | 49 | required, mount.cifs is recommended. Most distros include a "cifs-utils" |
65 | "net" may also be helpful since it may someday provide easier mount syntax for | 50 | package that includes this utility so it is recommended to install this. |
66 | users who are used to Windows e.g. | 51 | |
67 | net use <mount point> <UNC name or cifs URL> | ||
68 | Note that running the Winbind pam/nss module (logon service) on all of your | 52 | Note that running the Winbind pam/nss module (logon service) on all of your |
69 | Linux clients is useful in mapping Uids and Gids consistently across the | 53 | Linux clients is useful in mapping Uids and Gids consistently across the |
70 | domain to the proper network user. The mount.cifs mount helper can be | 54 | domain to the proper network user. The mount.cifs mount helper can be |
71 | trivially built from Samba 3.0 or later source e.g. by executing: | 55 | found at cifs-utils.git on git.samba.org |
72 | |||
73 | gcc samba/source/client/mount.cifs.c -o mount.cifs | ||
74 | 56 | ||
75 | If cifs is built as a module, then the size and number of network buffers | 57 | If cifs is built as a module, then the size and number of network buffers |
76 | and maximum number of simultaneous requests to one server can be configured. | 58 | and maximum number of simultaneous requests to one server can be configured. |
@@ -79,6 +61,18 @@ Changing these from their defaults is not recommended. By executing modinfo | |||
79 | on kernel/fs/cifs/cifs.ko the list of configuration changes that can be made | 61 | on kernel/fs/cifs/cifs.ko the list of configuration changes that can be made |
80 | at module initialization time (by running insmod cifs.ko) can be seen. | 62 | at module initialization time (by running insmod cifs.ko) can be seen. |
81 | 63 | ||
64 | Recommendations | ||
65 | =============== | ||
66 | To improve security the SMB2.1 dialect or later (usually will get SMB3) is now | ||
67 | the new default. To use old dialects (e.g. to mount Windows XP) use "vers=1.0" | ||
68 | on mount (or vers=2.0 for Windows Vista). Note that the CIFS (vers=1.0) is | ||
69 | much older and less secure than the default dialect SMB3 which includes | ||
70 | many advanced security features such as downgrade attack detection | ||
71 | and encrypted shares and stronger signing and authentication algorithms. | ||
72 | There are additional mount options that may be helpful for SMB3 to get | ||
73 | improved POSIX behavior (NB: can use vers=3.0 to force only SMB3, never 2.1): | ||
74 | "mfsymlinks" and "cifsacl" and "idsfromsid" | ||
75 | |||
82 | Allowing User Mounts | 76 | Allowing User Mounts |
83 | ==================== | 77 | ==================== |
84 | To permit users to mount and unmount over directories they own is possible | 78 | To permit users to mount and unmount over directories they own is possible |
@@ -98,9 +92,7 @@ and execution of suid programs on the remote target would be enabled | |||
98 | by default. This can be changed, as with nfs and other filesystems, | 92 | by default. This can be changed, as with nfs and other filesystems, |
99 | by simply specifying "nosuid" among the mount options. For user mounts | 93 | by simply specifying "nosuid" among the mount options. For user mounts |
100 | though to be able to pass the suid flag to mount requires rebuilding | 94 | though to be able to pass the suid flag to mount requires rebuilding |
101 | mount.cifs with the following flag: | 95 | mount.cifs with the following flag: CIFS_ALLOW_USR_SUID |
102 | |||
103 | gcc samba/source/client/mount.cifs.c -DCIFS_ALLOW_USR_SUID -o mount.cifs | ||
104 | 96 | ||
105 | There is a corresponding manual page for cifs mounting in the Samba 3.0 and | 97 | There is a corresponding manual page for cifs mounting in the Samba 3.0 and |
106 | later source tree in docs/manpages/mount.cifs.8 | 98 | later source tree in docs/manpages/mount.cifs.8 |
@@ -189,18 +181,18 @@ applications running on the same server as Samba. | |||
189 | Use instructions: | 181 | Use instructions: |
190 | ================ | 182 | ================ |
191 | Once the CIFS VFS support is built into the kernel or installed as a module | 183 | Once the CIFS VFS support is built into the kernel or installed as a module |
192 | (cifs.o), you can use mount syntax like the following to access Samba or Windows | 184 | (cifs.ko), you can use mount syntax like the following to access Samba or |
193 | servers: | 185 | Mac or Windows servers: |
194 | 186 | ||
195 | mount -t cifs //9.53.216.11/e$ /mnt -o user=myname,pass=mypassword | 187 | mount -t cifs //9.53.216.11/e$ /mnt -o username=myname,password=mypassword |
196 | 188 | ||
197 | Before -o the option -v may be specified to make the mount.cifs | 189 | Before -o the option -v may be specified to make the mount.cifs |
198 | mount helper display the mount steps more verbosely. | 190 | mount helper display the mount steps more verbosely. |
199 | After -o the following commonly used cifs vfs specific options | 191 | After -o the following commonly used cifs vfs specific options |
200 | are supported: | 192 | are supported: |
201 | 193 | ||
202 | user=<username> | 194 | username=<username> |
203 | pass=<password> | 195 | password=<password> |
204 | domain=<domain name> | 196 | domain=<domain name> |
205 | 197 | ||
206 | Other cifs mount options are described below. Use of TCP names (in addition to | 198 | Other cifs mount options are described below. Use of TCP names (in addition to |
@@ -246,13 +238,16 @@ the Server's registry. Samba starting with version 3.10 will allow such | |||
246 | filenames (ie those which contain valid Linux characters, which normally | 238 | filenames (ie those which contain valid Linux characters, which normally |
247 | would be forbidden for Windows/CIFS semantics) as long as the server is | 239 | would be forbidden for Windows/CIFS semantics) as long as the server is |
248 | configured for Unix Extensions (and the client has not disabled | 240 | configured for Unix Extensions (and the client has not disabled |
249 | /proc/fs/cifs/LinuxExtensionsEnabled). | 241 | /proc/fs/cifs/LinuxExtensionsEnabled). In addition the mount option |
250 | 242 | "mapposix" can be used on CIFS (vers=1.0) to force the mapping of | |
243 | illegal Windows/NTFS/SMB characters to a remap range (this mount parm | ||
244 | is the default for SMB3). This remap ("mapposix") range is also | ||
245 | compatible with Mac (and "Services for Mac" on some older Windows). | ||
251 | 246 | ||
252 | CIFS VFS Mount Options | 247 | CIFS VFS Mount Options |
253 | ====================== | 248 | ====================== |
254 | A partial list of the supported mount options follows: | 249 | A partial list of the supported mount options follows: |
255 | user The user name to use when trying to establish | 250 | username The user name to use when trying to establish |
256 | the CIFS session. | 251 | the CIFS session. |
257 | password The user password. If the mount helper is | 252 | password The user password. If the mount helper is |
258 | installed, the user will be prompted for password | 253 | installed, the user will be prompted for password |
diff --git a/Documentation/filesystems/cifs/TODO b/Documentation/filesystems/cifs/TODO index 066ffddc3964..396ecfd6ff4a 100644 --- a/Documentation/filesystems/cifs/TODO +++ b/Documentation/filesystems/cifs/TODO | |||
@@ -1,4 +1,4 @@ | |||
1 | Version 2.03 August 1, 2014 | 1 | Version 2.04 September 13, 2017 |
2 | 2 | ||
3 | A Partial List of Missing Features | 3 | A Partial List of Missing Features |
4 | ================================== | 4 | ================================== |
@@ -8,73 +8,69 @@ for visible, important contributions to this module. Here | |||
8 | is a partial list of the known problems and missing features: | 8 | is a partial list of the known problems and missing features: |
9 | 9 | ||
10 | a) SMB3 (and SMB3.02) missing optional features: | 10 | a) SMB3 (and SMB3.02) missing optional features: |
11 | - RDMA | 11 | - RDMA (started) |
12 | - multichannel (started) | 12 | - multichannel (started) |
13 | - directory leases (improved metadata caching) | 13 | - directory leases (improved metadata caching) |
14 | - T10 copy offload (copy chunk is only mechanism supported) | 14 | - T10 copy offload (copy chunk is only mechanism supported) |
15 | - encrypted shares | ||
16 | 15 | ||
17 | b) improved sparse file support | 16 | b) improved sparse file support |
18 | 17 | ||
19 | c) Directory entry caching relies on a 1 second timer, rather than | 18 | c) Directory entry caching relies on a 1 second timer, rather than |
20 | using FindNotify or equivalent. - (started) | 19 | using Directory Leases |
21 | 20 | ||
22 | d) quota support (needs minor kernel change since quota calls | 21 | d) quota support (needs minor kernel change since quota calls |
23 | to make it to network filesystems or deviceless filesystems) | 22 | to make it to network filesystems or deviceless filesystems) |
24 | 23 | ||
25 | e) improve support for very old servers (OS/2 and Win9x for example) | 24 | e) Better optimize open to reduce redundant opens (using reference |
26 | Including support for changing the time remotely (utimes command). | 25 | counts more) and to improve use of compounding in SMB3 to reduce |
26 | number of roundtrips. | ||
27 | 27 | ||
28 | f) hook lower into the sockets api (as NFS/SunRPC does) to avoid the | 28 | f) Finish inotify support so kde and gnome file list windows |
29 | extra copy in/out of the socket buffers in some cases. | ||
30 | |||
31 | g) Better optimize open (and pathbased setfilesize) to reduce the | ||
32 | oplock breaks coming from windows srv. Piggyback identical file | ||
33 | opens on top of each other by incrementing reference count rather | ||
34 | than resending (helps reduce server resource utilization and avoid | ||
35 | spurious oplock breaks). | ||
36 | |||
37 | h) Add support for storing symlink info to Windows servers | ||
38 | in the Extended Attribute format their SFU clients would recognize. | ||
39 | |||
40 | i) Finish inotify support so kde and gnome file list windows | ||
41 | will autorefresh (partially complete by Asser). Needs minor kernel | 29 | will autorefresh (partially complete by Asser). Needs minor kernel |
42 | vfs change to support removing D_NOTIFY on a file. | 30 | vfs change to support removing D_NOTIFY on a file. |
43 | 31 | ||
44 | j) Add GUI tool to configure /proc/fs/cifs settings and for display of | 32 | g) Add GUI tool to configure /proc/fs/cifs settings and for display of |
45 | the CIFS statistics (started) | 33 | the CIFS statistics (started) |
46 | 34 | ||
47 | k) implement support for security and trusted categories of xattrs | 35 | h) implement support for security and trusted categories of xattrs |
48 | (requires minor protocol extension) to enable better support for SELINUX | 36 | (requires minor protocol extension) to enable better support for SELINUX |
49 | 37 | ||
50 | l) Implement O_DIRECT flag on open (already supported on mount) | 38 | i) Implement O_DIRECT flag on open (already supported on mount) |
51 | 39 | ||
52 | m) Create UID mapping facility so server UIDs can be mapped on a per | 40 | j) Create UID mapping facility so server UIDs can be mapped on a per |
53 | mount or a per server basis to client UIDs or nobody if no mapping | 41 | mount or a per server basis to client UIDs or nobody if no mapping |
54 | exists. This is helpful when Unix extensions are negotiated to | 42 | exists. Also better integration with winbind for resolving SID owners |
55 | allow better permission checking when UIDs differ on the server | 43 | |
56 | and client. Add new protocol request to the CIFS protocol | 44 | k) Add tools to take advantage of more smb3 specific ioctls and features |
57 | standard for asking the server for the corresponding name of a | 45 | |
58 | particular uid. | 46 | l) encrypted file support |
47 | |||
48 | m) improved stats gathering, tools (perhaps integration with nfsometer?) | ||
59 | 49 | ||
60 | n) DOS attrs - returned as pseudo-xattr in Samba format (check VFAT and NTFS for this too) | 50 | n) allow setting more NTFS/SMB3 file attributes remotely (currently limited to compressed |
51 | file attribute via chflags) and improve user space tools for managing and | ||
52 | viewing them. | ||
61 | 53 | ||
62 | o) mount check for unmatched uids | 54 | o) mount helper GUI (to simplify the various configuration options on mount) |
63 | 55 | ||
64 | p) Add support for new vfs entry point for fallocate | 56 | p) autonegotiation of dialects (offering more than one dialect ie SMB3.02, |
57 | SMB3, SMB2.1 not just SMB3). | ||
65 | 58 | ||
66 | q) Add tools to take advantage of cifs/smb3 specific ioctls and features | 59 | q) Allow mount.cifs to be more verbose in reporting errors with dialect |
67 | such as "CopyChunk" (fast server side file copy) | 60 | or unsupported feature errors. |
68 | 61 | ||
69 | r) encrypted file support | 62 | r) updating cifs documentation, and user guid. |
70 | 63 | ||
71 | s) improved stats gathering, tools (perhaps integration with nfsometer?) | 64 | s) Addressing bugs found by running a broader set of xfstests in standard |
65 | file system xfstest suite. | ||
72 | 66 | ||
73 | t) allow setting more NTFS/SMB3 file attributes remotely (currently limited to compressed | 67 | t) split cifs and smb3 support into separate modules so legacy (and less |
74 | file attribute via chflags) | 68 | secure) CIFS dialect can be disabled in environments that don't need it |
69 | and simplify the code. | ||
75 | 70 | ||
76 | u) mount helper GUI (to simplify the various configuration options on mount) | 71 | u) Finish up SMB3.1.1 dialect support |
77 | 72 | ||
73 | v) POSIX Extensions for SMB3.1.1 | ||
78 | 74 | ||
79 | KNOWN BUGS | 75 | KNOWN BUGS |
80 | ==================================== | 76 | ==================================== |
diff --git a/Documentation/filesystems/cifs/cifs.txt b/Documentation/filesystems/cifs/cifs.txt index 2fac91ac96cf..67756607246e 100644 --- a/Documentation/filesystems/cifs/cifs.txt +++ b/Documentation/filesystems/cifs/cifs.txt | |||
@@ -1,24 +1,28 @@ | |||
1 | This is the client VFS module for the Common Internet File System | 1 | This is the client VFS module for the SMB3 NAS protocol as well |
2 | (CIFS) protocol which is the successor to the Server Message Block | 2 | older dialects such as the Common Internet File System (CIFS) |
3 | protocol which was the successor to the Server Message Block | ||
3 | (SMB) protocol, the native file sharing mechanism for most early | 4 | (SMB) protocol, the native file sharing mechanism for most early |
4 | PC operating systems. New and improved versions of CIFS are now | 5 | PC operating systems. New and improved versions of CIFS are now |
5 | called SMB2 and SMB3. These dialects are also supported by the | 6 | called SMB2 and SMB3. These dialects are also supported by the |
6 | CIFS VFS module. CIFS is fully supported by network | 7 | CIFS VFS module. CIFS is fully supported by network |
7 | file servers such as Windows 2000, 2003, 2008 and 2012 | 8 | file servers such as Windows 2000, 2003, 2008, 2012 and 2016 |
8 | as well by Samba (which provides excellent CIFS | 9 | as well by Samba (which provides excellent CIFS |
9 | server support for Linux and many other operating systems), so | 10 | server support for Linux and many other operating systems), Apple |
11 | systems, as well as most Network Attached Storage vendors, so | ||
10 | this network filesystem client can mount to a wide variety of | 12 | this network filesystem client can mount to a wide variety of |
11 | servers. | 13 | servers. |
12 | 14 | ||
13 | The intent of this module is to provide the most advanced network | 15 | The intent of this module is to provide the most advanced network |
14 | file system function for CIFS compliant servers, including better | 16 | file system function for SMB3 compliant servers, including advanced |
15 | POSIX compliance, secure per-user session establishment, high | 17 | security features, excellent parallelized high performance i/o, better |
16 | performance safe distributed caching (oplock), optional packet | 18 | POSIX compliance, secure per-user session establishment, encryption, |
19 | high performance safe distributed caching (leases/oplocks), optional packet | ||
17 | signing, large files, Unicode support and other internationalization | 20 | signing, large files, Unicode support and other internationalization |
18 | improvements. Since both Samba server and this filesystem client support | 21 | improvements. Since both Samba server and this filesystem client support |
19 | the CIFS Unix extensions, the combination can provide a reasonable | 22 | the CIFS Unix extensions (and in the future SMB3 POSIX extensions), |
20 | alternative to NFSv4 for fileserving in some Linux to Linux environments, | 23 | the combination can provide a reasonable alternative to other network and |
21 | not just in Linux to Windows environments. | 24 | cluster file systems for fileserving in some Linux to Linux environments, |
25 | not just in Linux to Windows (or Linux to Mac) environments. | ||
22 | 26 | ||
23 | This filesystem has an mount utility (mount.cifs) that can be obtained from | 27 | This filesystem has an mount utility (mount.cifs) that can be obtained from |
24 | 28 | ||