You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Azure file shares can be mounted in Linux distributions using the [SMB kernel client](https://wiki.samba.org/index.php/LinuxCIFS).
15
15
16
+
This article shows how to mount an SMB Azure file share using NTLMv2 authentication (storage account key). Using identity-based authentication is preferred for security reasons. See [Enable Active Directory authentication over SMB for Linux clients accessing Azure Files](storage-files-identity-auth-linux-kerberos-enable.md).
17
+
16
18
## Applies to
17
19
18
20
| File share type | SMB | NFS |
@@ -23,7 +25,7 @@ Azure file shares can be mounted in Linux distributions using the [SMB kernel cl
23
25
24
26
## Protocols
25
27
26
-
The recommended way to mount an Azure file share on Linux is using SMB 3.1.1. By default, Azure Files requires encryption in transit, which is supported by SMB 3.0+. Azure Files also supports SMB 2.1, which doesn't support encryption in transit, but you can't mount Azure file shares with SMB 2.1 from another Azure region or on-premises for security reasons. Unless your application specifically requires SMB 2.1, use SMB 3.1.1. SMB 2.1 support was added to Linux kernel version 3.7, so if you're using a version of the Linux kernel after 3.7, it should support SMB 2.1.
28
+
We recommend using SMB 3.1.1. By default, Azure Files requires encryption in transit, which is supported by SMB 3.0+. Azure Files also supports SMB 2.1, which doesn't support encryption in transit, but you can't mount Azure file shares with SMB 2.1 from another Azure region or on-premises for security reasons. Unless your application specifically requires SMB 2.1, use SMB 3.1.1. SMB 2.1 support was added to Linux kernel version 3.7, so if you're using a version of the Linux kernel after 3.7, it should support SMB 2.1.
27
29
28
30
| Distribution | SMB 3.1.1 (Recommended) | SMB 3.0 |
29
31
|-|-----------|---------|
@@ -33,7 +35,7 @@ The recommended way to mount an Azure file share on Linux is using SMB 3.1.1. By
If your Linux distribution isn't listed in the above table, you can check the Linux kernel version with the `uname` command:
38
+
If your Linux distribution isn't listed in the table, you can check the Linux kernel version with the `uname` command:
37
39
38
40
```bash
39
41
uname -r
@@ -231,7 +233,7 @@ MNT_ROOT="/media"
231
233
sudo mkdir -p $MNT_ROOT
232
234
```
233
235
234
-
To mount an Azure file share on Linux, use the storage account name as the username of the file share, and the storage account key as the password. Because the storage account credentials might change over time, you should store the credentials for the storage account separately from the mount configuration.
236
+
Use the storage account name as the username of the file share, and the storage account key as the password. Because the storage account credentials might change over time, you should store the credentials for the storage account separately from the mount configuration.
235
237
236
238
The following example shows how to create a file to store the credentials. Remember to replace `<resource-group-name>` and `<storage-account-name>` with the appropriate information for your environment.
237
239
@@ -316,7 +318,7 @@ sudo apt install autofs
316
318
```
317
319
# [RHEL](#tab/RHEL)
318
320
319
-
Same applies for CentOS or Oracle Linux
321
+
Same applies for CentOS or Oracle Linux:
320
322
321
323
On Red Hat Enterprise Linux 8+, use the `dnf` package manager:
322
324
```bash
@@ -387,9 +389,8 @@ You can use the following mount options when mounting SMB Azure file shares on L
387
389
| `dir_mode=` | n/a | Optional. If the server doesn't support the CIFS Unix extensions, this overrides the default mode for directories. |
388
390
|`handletimeout=`| n/a | Optional. The time (in milliseconds) for which the server should reserve the file handle after a failover waiting for the client to reconnect. |
389
391
390
-
## Next steps
392
+
## Next step
391
393
392
394
For more information about using SMB Azure file shares with Linux, see:
393
395
394
-
- [Remove SMB 1 on Linux](files-remove-smb1-linux.md)
395
396
- [Troubleshoot general SMB issues on Linux](/troubleshoot/azure/azure-storage/files-troubleshoot-linux-smb?toc=/azure/storage/files/toc.json)
0 commit comments