Skip to content

Commit ff6095b

Browse files
Merge pull request #267256 from MGoedtel/task209275
Refresh azure-netapp-files-dual-protocol
2 parents 9a9bbba + 8984891 commit ff6095b

File tree

1 file changed

+52
-64
lines changed

1 file changed

+52
-64
lines changed

articles/aks/azure-netapp-files-dual-protocol.md

Lines changed: 52 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,20 @@ title: Provision Azure NetApp Files dual-protocol volumes for Azure Kubernetes S
33
description: Describes how to statically provision Azure NetApp Files dual-protocol volumes for Azure Kubernetes Service.
44
ms.topic: article
55
ms.custom:
6-
ms.date: 05/08/2023
6+
ms.date: 02/26/2024
77
---
88

99
# Provision Azure NetApp Files dual-protocol volumes for Azure Kubernetes Service
1010

11-
After you [configure Azure NetApp Files for Azure Kubernetes Service](azure-netapp-files.md), you can provision Azure NetApp Files volumes for Azure Kubernetes Service.
11+
After you [configure Azure NetApp Files for Azure Kubernetes Service][azure-netapp-files], you can provision Azure NetApp Files volumes for Azure Kubernetes Service.
1212

13-
Azure NetApp Files supports volumes using [NFS](azure-netapp-files-nfs.md) (NFSv3 or NFSv4.1), [SMB](azure-netapp-files-smb.md), and dual-protocol (NFSv3 and SMB, or NFSv4.1 and SMB).
14-
* This article describes details for statically provisioning volumes for dual-protocol access.
15-
* For information about provisioning SMB volumes statically or dynamically, see [Provision Azure NetApp Files SMB volumes for Azure Kubernetes Service](azure-netapp-files-smb.md).
16-
* For information about provisioning NFS volumes statically or dynamically, see [Provision Azure NetApp Files NFS volumes for Azure Kubernetes Service](azure-netapp-files-nfs.md).
13+
Azure NetApp Files supports volumes using [NFS][azure-netapp-nfs] (NFSv3 or NFSv4.1), [SMB][azure-netapp-smb], and dual-protocol (NFSv3 and SMB, or NFSv4.1 and SMB).
14+
15+
This article shows you how to statically provisioning volumes for dual-protocol access using NFS or SMB.
1716

1817
## Before you begin
1918

20-
* You must have already created a dual-protocol volume. See [create a dual-protocol volume for Azure NetApp Files](../azure-netapp-files/create-volumes-dual-protocol.md).
19+
* Make sure you have already created a dual-protocol volume. See [create a dual-protocol volume for Azure NetApp Files][azure-netapp-files-volume-dual-protocol].
2120

2221
## Provision a dual-protocol volume in Azure Kubernetes Service
2322

@@ -34,9 +33,9 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
3433
ANF_ACCOUNT_NAME="myaccountname"
3534
POOL_NAME="mypool1"
3635
VOLUME_NAME="myvolname"
37-
```
38-
39-
2. List the details of your volume using [`az netappfiles volume show`](/cli/azure/netappfiles/volume#az-netappfiles-volume-show) command.
36+
```
37+
38+
2. List the details of your volume using the [`az netappfiles volume show`][az-netappfiles-volume-show] command.
4039
4140
```azurecli-interactive
4241
az netappfiles volume show \
@@ -46,7 +45,7 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
4645
--volume-name $VOLUME_NAME -o JSON
4746
```
4847
49-
The following output is an example of the above command executed with real values.
48+
The following output is an example of the above command executed with real values.
5049
5150
```output
5251
{
@@ -83,13 +82,13 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
8382
path: /myfilepath2
8483
```
8584
86-
4. Create the persistent volume using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
85+
4. Create the persistent volume using the [`kubectl apply`][kubectl-apply] command:
8786
8887
```bash
8988
kubectl apply -f pv-nfs.yaml
9089
```
9190
92-
5. Verify the status of the persistent volume is *Available* by using the [`kubectl describe`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe) command:
91+
5. Verify the status of the persistent volume is *Available* by using the [`kubectl describe`][kubectl-describe] command:
9392
9493
```bash
9594
kubectl describe pv pv-nfs
@@ -113,13 +112,13 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
113112
storage: 100Gi
114113
```
115114
116-
2. Create the persistent volume claim using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
115+
2. Create the persistent volume claim using the [`kubectl apply`][kubectl-apply] command:
117116
118117
```bash
119118
kubectl apply -f pvc-nfs.yaml
120119
```
121120
122-
3. Verify the *Status* of the persistent volume claim is *Bound* by using the [`kubectl describe`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe) command:
121+
3. Verify the *Status* of the persistent volume claim is *Bound* by using the [`kubectl describe`][kubectl-describe] command:
123122
124123
```bash
125124
kubectl describe pvc pvc-nfs
@@ -151,19 +150,19 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
151150
claimName: pvc-nfs
152151
```
153152
154-
2. Create the pod using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
153+
2. Create the pod using the [`kubectl apply`][kubectl-apply][kubectl-apply] command:
155154
156155
```bash
157156
kubectl apply -f nginx-nfs.yaml
158157
```
159158
160-
3. Verify the pod is *Running* by using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
159+
3. Verify the pod is *Running* by using the [`kubectl apply`][kubectl-apply] command:
161160
162161
```bash
163162
kubectl describe pod nginx-nfs
164163
```
165164
166-
4. Verify your volume has been mounted on the pod by using [`kubectl exec`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#exec) to connect to the pod, and then use `df -h` to check if the volume is mounted.
165+
4. Verify your volume has been mounted on the pod by using [`kubectl exec`][kubectl-exec] to connect to the pod, and then use `df -h` to check if the volume is mounted.
167166
168167
```bash
169168
kubectl exec -it nginx-nfs -- sh
@@ -181,38 +180,43 @@ This section describes how to expose an Azure NetApp Files dual-protocol volume
181180
182181
### Create a secret with the domain credentials
183182
184-
1. Create a secret on your AKS cluster to access the AD server using the [`kubectl create secret`](https://kubernetes.io/docs/tasks/configmap-secret/managing-secret-using-kubectl/) command. This secret will be used by the Kubernetes persistent volume to access the Azure NetApp Files SMB volume. Use the following command to create the secret, replacing `USERNAME` with your username, `PASSWORD` with your password, and `DOMAIN_NAME` with your domain name for your Active Directory.
183+
1. Create a secret on your AKS cluster to access the AD server using the [`kubectl create secret`][kubectl-create-secret] command. This secret will be used by the Kubernetes persistent volume to access the Azure NetApp Files SMB volume. Use the following command to create the secret, replacing `USERNAME` with your username, `PASSWORD` with your password, and `DOMAIN_NAME` with your Active Directory domain name.
185184
186185
```bash
187186
kubectl create secret generic smbcreds --from-literal=username=USERNAME --from-literal=password="PASSWORD" --from-literal=domain='DOMAIN_NAME'
188187
```
189188
190-
2. Check the secret has been created.
189+
2. To verify the secret has been created, run the [`kubectl get`][kubectl-get] command.
191190
192191
```bash
193192
kubectl get secret
193+
```
194+
195+
```output
194196
NAME TYPE DATA AGE
195197
smbcreds Opaque 2 20h
196198
```
197199
198200
### Install an SMB CSI driver
199201
200-
You must install a Container Storage Interface (CSI) driver to create a Kubernetes SMB `PersistentVolume`.
202+
You must install a Container Storage Interface (CSI) driver to create a Kubernetes SMB `PersistentVolume`.
201203
202-
1. Install the SMB CSI driver on your cluster using helm. Be sure to set the `windows.enabled` option to `true`:
204+
1. Install the SMB CSI driver on your cluster using helm. Be sure to set the `windows.enabled` option to `true`:
203205
204206
```bash
205207
helm repo add csi-driver-smb https://raw.githubusercontent.com/kubernetes-csi/csi-driver-smb/master/charts
206208
helm install csi-driver-smb csi-driver-smb/csi-driver-smb --namespace kube-system --version v1.10.0 –-set windows.enabled=true
207209
```
208210
209-
For other methods of installing the SMB CSI Driver, see [Install SMB CSI driver master version on a Kubernetes cluster](https://github.com/kubernetes-csi/csi-driver-smb/blob/master/docs/install-csi-driver-master.md).
211+
For other methods of installing the SMB CSI Driver, see [Install SMB CSI driver master version on a Kubernetes cluster][install-smb-csi-driver].
210212
211-
2. Verify that the `csi-smb` controller pod is running and each worker node has a pod running using the [`kubectl get pods`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#get) command:
213+
2. Verify the `csi-smb` controller pod is running and each worker node has a pod running using the [`kubectl get pods`][kubectl-get-pods] command:
212214
213215
```bash
214216
kubectl get pods -n kube-system | grep csi-smb
215-
217+
```
218+
219+
```output
216220
csi-smb-controller-68df7b4758-xf2m9 3/3 Running 0 3m46s
217221
csi-smb-node-s6clj 3/3 Running 0 3m47s
218222
csi-smb-node-win-tfxvk 3/3 Running 0 3m47s
@@ -227,9 +231,9 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
227231
ANF_ACCOUNT_NAME="myaccountname"
228232
POOL_NAME="mypool1"
229233
VOLUME_NAME="myvolname"
230-
```
231-
232-
2. List the details of your volume using [`az netappfiles volume show`](/cli/azure/netappfiles/volume#az-netappfiles-volume-show).
234+
```
235+
236+
2. List the details of your volume using [`az netappfiles volume show`][az-netappfiles-volume-show] command.
233237
234238
```azurecli-interactive
235239
az netappfiles volume show \
@@ -239,7 +243,7 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
239243
--volume-name "$VOLUME_NAME -o JSON
240244
```
241245
242-
The following output is an example of the above command executed with real values.
246+
The following output is an example of the above command executed with real values.
243247
244248
```output
245249
{
@@ -287,21 +291,21 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
287291
namespace: default
288292
```
289293
290-
4. Create the persistent volume using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
294+
4. Create the persistent volume using the [`kubectl apply`][kubectl-apply] command:
291295
292296
```bash
293297
kubectl apply -f pv-smb.yaml
294298
```
295299
296-
5. Verify the status of the persistent volume is *Available* using the [`kubectl describe`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe) command:
300+
5. Verify the status of the persistent volume is *Available* using the [`kubectl describe`][kubectl-describe] command:
297301
298302
```bash
299303
kubectl describe pv anf-pv-smb
300304
```
301305
302306
### Create a persistent volume claim for SMB
303307
304-
1. Create a file name `pvc-smb.yaml` and copy in the following YAML.
308+
1. Create a file name `pvc-smb.yaml` and copy in the following YAML.
305309
306310
```yaml
307311
apiVersion: v1
@@ -318,19 +322,19 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
318322
storage: 100Gi
319323
```
320324
321-
2. Create the persistent volume claim using the [`kubectl apply`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
325+
2. Create the persistent volume claim using the [`kubectl apply`][kubectl-apply] command:
322326
323327
```bash
324328
kubectl apply -f pvc-smb.yaml
325329
```
326330
327-
Verify the status of the persistent volume claim is *Bound* by using the [`kubectl describe`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe) command:
331+
Verify the status of the persistent volume claim is *Bound* by using the [`kubectl describe`][kubectl-describe] command:
328332
329333
```bash
330334
kubectl describe pvc anf-pvc-smb
331335
```
332336
333-
### Mount within a pod using SMB
337+
### Mount within a pod using SMB
334338
335339
1. Create a file named `iis-smb.yaml` and copy in the following YAML. This file will be used to create an Internet Information Services pod to mount the volume to path `/inetpub/wwwroot`.
336340
@@ -363,19 +367,19 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
363367
readOnly: false
364368
```
365369
366-
2. Create the pod using the [kubectl apply](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply) command:
370+
2. Create the pod using the [kubectl apply][kubectl-apply] command:
367371
368372
```bash
369373
kubectl apply -f iis-smb.yaml
370374
```
371375
372-
3. Verify the pod is *Running* and `/inetpub/wwwroot` is mounted from SMB by using the [`kubectl describe`](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe) command:
376+
3. Verify the pod is *Running* and `/inetpub/wwwroot` is mounted from SMB by using the [`kubectl describe`][kubectl-describe] command:
373377
374378
```bash
375379
kubectl describe pod iis-pod
376380
```
377381
378-
The output of the command resembles the following example:
382+
The output of the command resembles the following example:
379383
380384
```output
381385
Name: iis-pod
@@ -413,12 +417,13 @@ You must install a Container Storage Interface (CSI) driver to create a Kubernet
413417
...
414418
```
415419
416-
4. Verify your volume has been mounted on the pod by using the [kubectl exec](https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#exec) command to connect to the pod, and then use `dir` command in the correct directory to check if the volume is mounted and the size matches the size of the volume you provisioned.
420+
4. Verify your volume has been mounted on the pod by using the [kubectl exec][kubectl-exec] command to connect to the pod. Then use the `dir` command in the correct directory to check if the volume is mounted and the size matches the size of the volume you provisioned.
417421
418422
```bash
419423
kubectl exec -it iis-pod –- cmd.exe
420424
```
421-
The output of the command resembles the following example:
425+
426+
The output of the command resembles the following example:
422427
423428
```output
424429
Microsoft Windows [Version 10.0.20348.1668]
@@ -449,37 +454,20 @@ Astra Trident supports many features with Azure NetApp Files. For more informati
449454
* [Importing volumes][importing-trident-volumes]
450455
451456
<!-- EXTERNAL LINKS -->
452-
[astra-trident]: https://docs.netapp.com/us-en/trident/index.html
453-
[kubectl-create]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#create
454457
[kubectl-apply]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply
455458
[kubectl-describe]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe
456459
[kubectl-exec]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#exec
457-
[astra-control-service]: https://cloud.netapp.com/astra-control
458-
[kubernetes-csi-driver]: https://kubernetes-csi.github.io/docs/
459-
[trident-install-guide]: https://docs.netapp.com/us-en/trident/trident-get-started/kubernetes-deploy.html
460-
[trident-helm-chart]: https://docs.netapp.com/us-en/trident/trident-get-started/kubernetes-deploy-operator.html
461-
[tridentctl]: https://docs.netapp.com/us-en/trident/trident-get-started/kubernetes-deploy-tridentctl.html
462-
[trident-backend-install-guide]: https://docs.netapp.com/us-en/trident/trident-use/backends.html
460+
[kubectl-create-secret]: https://kubernetes.io/docs/tasks/configmap-secret/managing-secret-using-kubectl/
461+
[kubectl-get-pods]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#get
463462
[kubectl-get]: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#get
464463
[expand-trident-volumes]: https://docs.netapp.com/us-en/trident/trident-use/vol-expansion.html
464+
[install-smb-csi-driver]: https://github.com/kubernetes-csi/csi-driver-smb/blob/master/docs/install-csi-driver-master.md
465465
[on-demand-trident-volume-snapshots]: https://docs.netapp.com/us-en/trident/trident-use/vol-snapshots.html
466466
[importing-trident-volumes]: https://docs.netapp.com/us-en/trident/trident-use/vol-import.html
467-
[backend-anf.yaml]: https://raw.githubusercontent.com/NetApp/trident/v23.01.1/trident-installer/sample-input/backends-samples/azure-netapp-files/backend-anf.yaml
468467
469468
<!-- INTERNAL LINKS -->
470-
[aks-quickstart-cli]: ./learn/quick-kubernetes-deploy-cli.md
471-
[aks-quickstart-portal]: ./learn/quick-kubernetes-deploy-portal.md
472-
[aks-quickstart-powershell]: ./learn/quick-kubernetes-deploy-powershell.md
473-
[anf]: ../azure-netapp-files/azure-netapp-files-introduction.md
474-
[anf-delegate-subnet]: ../azure-netapp-files/azure-netapp-files-delegate-subnet.md
475-
[anf-regions]: https://azure.microsoft.com/global-infrastructure/services/?products=netapp&regions=all
476-
[az-aks-show]: /cli/azure/aks#az_aks_show
477-
[az-netappfiles-account-create]: /cli/azure/netappfiles/account#az_netappfiles_account_create
478-
[az-netapp-files-dynamic]: azure-netapp-files-dynamic.md
479-
[az-netappfiles-pool-create]: /cli/azure/netappfiles/pool#az_netappfiles_pool_create
480-
[az-netappfiles-volume-create]: /cli/azure/netappfiles/volume#az_netappfiles_volume_create
481469
[az-netappfiles-volume-show]: /cli/azure/netappfiles/volume#az_netappfiles_volume_show
482-
[az-network-vnet-subnet-create]: /cli/azure/network/vnet/subnet#az_network_vnet_subnet_create
483-
[install-azure-cli]: /cli/azure/install-azure-cli
484-
[use-tags]: use-tags.md
485-
[azure-ad-app-registration]: ../active-directory/develop/howto-create-service-principal-portal.md
470+
[azure-netapp-nfs]: azure-netapp-files-nfs.md
471+
[azure-netapp-smb]: azure-netapp-files-smb.md
472+
[azure-netapp-files]: azure-netapp-files.md
473+
[azure-netapp-files-volume-dual-protocol]: ../azure-netapp-files/create-volumes-dual-protocol.md

0 commit comments

Comments
 (0)