The company is geographically dispersed with offices in different locations. These offices need a way to share files and disseminate information. For example, the Finance department needs to confirm cost information for auditing and compliance. This file shares should be easy to access and load without delay. Some content should only be accessed from selected corporate virtual networks.
Architecture diagram
Skilling tasks
- Create a storage account specifically for file shares.
- Configure a file share and directory.
- Configure snapshots and practice restoring files.
- Restrict access to a specific virtual network and subnet.
Exercise instructions
Note: To complete this lab you will need an Azure subscription.
Create and configure a storage account for Azure Files.
-
Create a storage account for the finance department’s shared files. Learn more about storage accounts for Azure Files deployments.
- In the portal, search for and select
Storage accounts
. - Select + Create.
- For Resource group select Create new. Give your resource group a name and select OK to save your changes.
- Provide a Storage account name. Ensure the name meets the naming requirements.
- Set the Performance to Premium.
- Set the Premium account type to File shares.
- Set the Redundancy to Zone-redundant storage.
- Select Review and then Create the storage account.
- Wait for the resource to deploy.
- Select Go to resource.
- In the portal, search for and select
Create and configure a file share with directory.
-
Create a file share for the corporate office. Learn more about Azure File tiers.
- In the storage account, in the Data storage section, select the File shares blade.
- Select + File share and provide a Name.
- Review the other options, but take the defaults.
- Select Create
-
Add a directory to the file share for the finance department. For future testing, upload a file.
- Select your file share and select + Add directory.
- Name the new directory
finance
. - Select Browse and then select the finance directory.
- Notice you can Add directory to further organize your file share.
- Upload a file of your choosing.
Configure and test snapshots.
-
Similar to blob storage, you need to protect against accidental deletion of files. You decide to use snapshots. Learn more about file snapshots.
- Select your file share.
- In the Operations section, select the Snapshots blade.
- Select + Add snapshot. The comment is optional. Select OK.
- Select your snapshot and verify your file directory and uploaded file are included.
-
Practice using snapshots to restore a file.
- Return to your file share.
- Browse to your file directory.
- Locate your uploaded file and in the Properties pane select Delete. Select Yes to confirm the deletion.
- Select the Snapshots blade and then select your snapshot.
- Navigate to the file you want to restore,
- Select the file and the select Restore.
- Provide a Restored file name.
- Verify your file directory has the restored file.
Configure restricting storage access to selected virtual networks.
- This tasks in this section require a virtual network with subnet. In a production environment these resources would already be created.
- Search for and select Virtual networks.
- Select Create. Select your resource group. and give the virtual network a name.
- Take the defaults for other parameters, select Review + create, and then Create.
- Wait for the resource to deploy.
- Select Go to resource.
- In the Settings section, select the Subnets blade.
- Select the default subnet.
- In the Service endpoints section choose Microsoft.Storage in the Services drop-down.
- Do not make any other changes.
- Be sure to Save your changes.
- Search for and select Virtual networks.
-
The storage account should only be accessed from the virtual network you just created. Learn more about using private storage endpoints..
- Return to your files storage account.
- In the Security + networking section, select the Networking blade.
- Change the Public network access to Enabled from selected virtual networks and IP addresses.
- In the Virtual networks section, select Add existing virtual network.
- Select your virtual network and subnet, select Add.
- Be sure to Save your changes.
- Select the Storage browser and navigate to your file share.
- Verify the message not authorized to perform this operation. You are not connecting from the virtual network.
Note: For additional practice complete the Configure Azure storage security module. The module has an interactive lab simulation where you can get more practice creating secure storage.
Extend your learning with Copilot
Copilot can assist you in your learning journey. Copilot can provide basic technical information, high-level steps, pros and cons, troubleshooting help, usage cases, coding examples, and much more. To access Copilot, open an Edge browser and choose Copilot (top right). Take a few minutes to try these prompts.
- What is Azure File storage and how is it different from Azure blob storage? How do I decide which one to use?
- What are the different ways to secure Azure file content?
Learn more with self-paced training
- Configure Azure Files and Azure File Sync. In this module, you learn to configure Azure file shares and file share snapshots.
Key takeaways
Congratulations on completing the lab. Here are the main takeaways for this lab.
- Azure Files offers fully managed file shares in the cloud that are accessible via the industry standard Server Message Block (SMB) protocol, Network File System (NFS) protocol, and Azure Files REST API.
- Azure Files provides the capability to take snapshots of SMB and NFS file shares. Share snapshots capture the share state at that point in time. Share snapshots provide only file-level protection.
- You can configure a storage account endpoint for accessing the Azure file share directly. Endpoints to restrict network access to your storage account.