Configuration and connection to Network File System on Windows Server 2022 Azure
For the connection to the server you should know the IP address of the VM. You can find it in the personal account of Azure. (You need to select the virtual machine from the list. By clicking the item “Overview”, your IP is displayed in the line of “Public IP Address”).
For the VM to work, you need to open ports 111 and 2049 (TCP and UDP) in the network properties in Azure Firefall.
Connecting and configuring the VM
- Run the “Remote Desktop Connection” shortcut “Win + R”. In the window that appears, enter “mstsc” and click “OK”.
- In the window that appears, enter the IP of the virtual machine and click “Connect”.
- In the window that appears, enter your username and password and click “OK”.
- Check the box and click “Yes”.
- Once logged in, open up “Server Manager“ (if it doesn’t start automatically)
- Select “File and Storage Services” in the window that opens.
- Select the “Shares” section, click “TASKS” – New Share.
- Select “NFS Share – Quick” and click “Next” in the window that appears.
- For example, you can configure a specific folder as Shared. To do this, you should click on “Type a custom path” and select a folder or write the name of the folder, which will be created in the directory you selected, if there is no such folder. Click “Next”.
(Share_folder is an example of a folder name, it is not necessary to specify it exactly. You can specify any folder that you want to make available on your VM)
- Click “Next”, click “OK” (in case in the previous step you wrote the name of the folder that would be created)
- Specify authentication methods.
- Set the share permissions. Click the “Add” button.
- Specify the Hosts you’d like to grant access permissions like the example below. Enter IP address and choose permissions that will be available to this host.
- Click “Next”.
- Click “Create”.
- Click “Close”.
- Now you can manage the NFS server with ‘NFS tools’
Connecting to NFS Share
- Press the “Start” button, enter “windows features” and open this menu.
- In this window, scroll down to “Services for NFS” and check the box “Client for NFS” then click the “OK” button.
- Open “Explorer – This PC”, select “Computer – Map network drive – Map network drive” on top.
- Enter \\vm_ip\shared_folder and click “Finish”.
Vm_ip and share_folder are given as an example, you should insert the IP address of your VM instead of vm_ip, and instead of share_folder you should insert the Share name of your NFS.