Mount a volume for Windows or Linux VMs
You can mount an Azure NetApp Files file for Windows or Linux virtual machines (VMs). The mount instructions for Linux virtual machines are available on Azure NetApp Files.
Requirements
- You must have at least one export policy to be able to access an NFS volume.
- To mount an NFS volume successfully, ensure that the following NFS ports are open between the client and the NFS volumes:
- 111 TCP/UDP =
RPCBIND/Portmapper - 635 TCP/UDP =
mountd - 2049 TCP/UDP =
nfs - 4045 TCP/UDP =
nlockmgr(NFSv3 only) - 4046 TCP/UDP =
status(NFSv3 only)
- 111 TCP/UDP =
Steps
Click the Volumes blade, and then select the volume for which you want to mount.
Click Mount instructions from the selected volume, and then follow the instructions to mount the volume.


- If you are mounting an NFS volume, ensure that you use the
versoption in themountcommand to specify the NFS protocol version that corresponds to the volume you want to mount. - If you are using NFSv4.1, use the following command to mount your file system:
sudo mount -t nfs -o rw,hard,rsize=65536,wsize=65536,vers=4.1,tcp,sec=sys $MOUNTTARGETIPADDRESS:/$VOLUMENAME $MOUNTPOINTNote
If you use NFSv4.1 and your use case involves leveraging VMs with the same hostnames (for example, in a DR test), see Configure two VMs with the same hostname to access NFSv4.1 volumes.
- If you are mounting an NFS volume, ensure that you use the
If you want to have an NFS volume automatically mounted when an Azure VM is started or rebooted, add an entry to the
/etc/fstabfile on the host.For example:
$ANFIP:/$FILEPATH /$MOUNTPOINT nfs bg,rw,hard,noatime,nolock,rsize=65536,wsize=65536,vers=3,tcp,_netdev 0 0$ANFIPis the IP address of the Azure NetApp Files volume found in the volume properties blade.$FILEPATHis the export path of the Azure NetApp Files volume.$MOUNTPOINTis the directory created on the Linux host used to mount the NFS export.
If you want to mount the volume to Windows using NFS:
a. Mount the volume onto a Unix or Linux VM first.
b. Run achmod 777orchmod 775command against the volume.
c. Mount the volume via the NFS client on Windows.If you want to mount an NFS Kerberos volume, see Configure NFSv4.1 Kerberos encryption for additional details.
Next steps
Maklum balas
Kirim dan lihat maklum balas untuk