Sign in to the Azure portal https://portal.azure.com.
Navigate to the Storage account in this example the storage account name is reggiestorage40
Select the storage account then click on file shares as shown in the diagram below.
Click the + sign on the File Shares tab
- Select the file share you want to mount and give it a name, here in this sample I gave it reggiefileshare and give it tier HOT to indicate it would be accessed frequently then leave others as default.
Then next is backup which is optional since it is a lab environment you can choose to disable this section by unchecking the radio button next to enable backup.
On the page just click on review and create it would carry out a validation check and if you follow the steps in this blog it would pass then click Create
After the above step your file share is created then you click on connect as shown in the diagram below and choose the drive letter of your choice in the image below I assigned S then scroll down and click on show script and copy the script.
For you to mount it on your local PC you paste the script in a PowerShell as shown in the diagram below then it would check if port 445 is open on the firewall and accessible if it shows succeeded as in the diagram below then you press enter and file share is mounted
The file share is mounted on your computer as a local drive. You can access the files in the file share by opening the drive in File Explorer as shown in the diagram below.
Then when you are done and you finally delete the file share from the storage account in the Azure portal or storage explorer, you will use this command as shown in the diagram below to remove the shortcut from your PC. In this diagram, the drive letter I used was S because I changed it from the default which is Z. So please take note. The command is for example net use drive letter: /delete.
This is the command if you are using the default drive net use Z: /delete.
In the diagram below I had changed the drive letter to S hence the reason for the command I used below.
note: if you create two storage accounts and want to create file share for both of them you have to create them using two different drive letters.
If you find this article helpful, please like, comment and share it. Thanks