Skip to content

Commit a71e530

Browse files
authored
AB#5601: Post Edit for PR#8808
1 parent ca3039a commit a71e530

File tree

1 file changed

+45
-43
lines changed

1 file changed

+45
-43
lines changed
Lines changed: 45 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Recommended and useful mountOptions settings on Azure Files
33
description: Learn about the useful and recommended mountOptions settings when you configure the storage class object on Azure Files.
4-
ms.date: 04/25/2025
4+
ms.date: 04/27/2025
55
ms.reviewer: chiragpa, nickoman, v-leedennis
66
ms.service: azure-kubernetes-service
77
#Customer intent: As an Azure Kubernetes user, I want to learn about mount option settings so that I can set up my Azure Files storage class object optimally on my Azure Kubernetes Service (AKS) cluster.
@@ -13,54 +13,56 @@ This article discusses recommended mount options when you configure the storage
1313

1414
## Recommended settings
1515

16-
The following `mountOptions` are recommended for SMB and NFS shares:
16+
The following `mountOptions` settings are recommended for Server Message Block (SMB) and Network File System (NFS) shares:
1717

18-
**SMB shares**
18+
- **SMB shares**
1919

20-
```yaml
21-
apiVersion: storage.k8s.io/v1
22-
kind: StorageClass
23-
metadata:
24-
name: azurefile-csi
25-
provisioner: file.csi.azure.com
26-
allowVolumeExpansion: true
27-
parameters:
28-
skuName: Premium_LRS # available values: Premium_LRS, Premium_ZRS, Standard_LRS, Standard_GRS, Standard_ZRS, Standard_RAGRS, Standard_RAGZRS
29-
reclaimPolicy: Delete
30-
volumeBindingMode: Immediate
31-
mountOptions:
32-
- dir_mode=0777 # modify this permission if you want to enhance the security
33-
- file_mode=0777 # modify this permission if you want to enhance the security
34-
- mfsymlinks # support symbolic links
35-
- cache=strict # https://linux.die.net/man/8/mount.cifs
36-
- nosharesock # reduces probability of reconnect race
37-
- actimeo=30 # reduces latency for metadata-heavy workload
38-
- nobrl # disable sending byte range lock requests to the server and for applications which have challenges with posix locks
39-
```
20+
```yaml
21+
apiVersion: storage.k8s.io/v1
22+
kind: StorageClass
23+
metadata:
24+
name: azurefile-csi
25+
provisioner: file.csi.azure.com
26+
allowVolumeExpansion: true
27+
parameters:
28+
skuName: Premium_LRS # available values: Premium_LRS, Premium_ZRS, Standard_LRS, Standard_GRS, Standard_ZRS, Standard_RAGRS, Standard_RAGZRS
29+
reclaimPolicy: Delete
30+
volumeBindingMode: Immediate
31+
mountOptions:
32+
- dir_mode=0777 # modify this permission if you want to enhance the security
33+
- file_mode=0777 # modify this permission if you want to enhance the security
34+
- mfsymlinks # support symbolic links
35+
- cache=strict # https://linux.die.net/man/8/mount.cifs
36+
- nosharesock # reduces probability of reconnect race
37+
- actimeo=30 # reduces latency for metadata-heavy workload
38+
- nobrl # disable sending byte range lock requests to the server and for applications which have challenges with posix locks
39+
```
4040
41-
**NFS shares**
41+
- **NFS shares**
4242
43-
```yaml
44-
apiVersion: storage.k8s.io/v1
45-
kind: StorageClass
46-
metadata:
47-
name: azurefile-csi-nfs
48-
provisioner: file.csi.azure.com
49-
parameters:
50-
protocol: nfs
51-
skuName: Premium_LRS # available values: Premium_LRS, Premium_ZRS
52-
reclaimPolicy: Delete
53-
volumeBindingMode: Immediate
54-
allowVolumeExpansion: true
55-
mountOptions:
56-
- nconnect=4 # improves performance by enabling multiple connections to share
57-
- noresvport # improves availability
58-
- actimeo=30 # reduces latency for metadata-heavy workloads
59-
```
43+
```yaml
44+
apiVersion: storage.k8s.io/v1
45+
kind: StorageClass
46+
metadata:
47+
name: azurefile-csi-nfs
48+
provisioner: file.csi.azure.com
49+
parameters:
50+
protocol: nfs
51+
skuName: Premium_LRS # available values: Premium_LRS, Premium_ZRS
52+
reclaimPolicy: Delete
53+
volumeBindingMode: Immediate
54+
allowVolumeExpansion: true
55+
mountOptions:
56+
- nconnect=4 # improves performance by enabling multiple connections to share
57+
- noresvport # improves availability
58+
- actimeo=30 # reduces latency for metadata-heavy workloads
59+
```
6060
6161
> [!NOTE]
62-
> The location to configure mount options (mountOptions) depends on whether you're provisioning dynamic or static persistent volumes. If you're [dynamically provisioning a volume](/azure/aks/azure-csi-files-storage-provision#dynamically-provision-a-volume) with a storage class, specify the mount options on the storage class object (kind: StorageClass). If youre [statically provisioning a volume](/azure/aks/azure-csi-files-storage-provision#statically-provision-a-volume), specify the mount options on the PersistentVolume object (kind: PersistentVolume). If youre [mounting the file share as an inline volume](/azure/aks/azure-csi-files-storage-provision#mount-file-share-as-an-inline-volume), specify the mount options on the Pod object (kind: Pod).
62+
> The location for configuring mount options (`mountOptions`) depends on whether you're provisioning dynamic or static persistent volumes. If you're [dynamically provisioning a volume](/azure/aks/azure-csi-files-storage-provision#dynamically-provision-a-volume) with a storage class, specify the mount options on the storage class object (`kind: StorageClass`). If you're [statically provisioning a volume](/azure/aks/azure-csi-files-storage-provision#statically-provision-a-volume), specify the mount options on the `PersistentVolume` object (`kind: PersistentVolume`). If you're [mounting the file share as an inline volume](/azure/aks/azure-csi-files-storage-provision#mount-file-share-as-an-inline-volume), specify the mount options on the `Pod` object (`kind: Pod`).
6363

64-
For best practices when using Azure Files, see [Provision Azure Files storage](/azure/aks/azure-csi-files-storage-provision#best-practices).
64+
## More information
65+
66+
For Azure Files best practices, see [Provision Azure Files storage](/azure/aks/azure-csi-files-storage-provision#best-practices).
6567

6668
[!INCLUDE [Azure Help Support](../../../includes/azure-help-support.md)]

0 commit comments

Comments
 (0)