Edit

Share via


Create an Azure file share with Microsoft.FileShares (preview)

The new Microsoft.FileShares resource provider (preview) and management model allows you to deploy file shares without creating an Azure storage account. Before you create an Azure file share with the Microsoft.FileShares resource provider, review the following to decide if it's the right fit for your needs. If you need all the features that Azure Files offers, or you need to use the SMB protocol, or want HDD (standard) performance, use a classic file share instead.

  • The Microsoft.FileShares resource provider and management model is current only available for NFS file shares, which require SSD (premium) storage. SSD media provides consistent high performance and low latency, within single-digit milliseconds for most IO operations.

  • The preview only supports the provisioned v2 billing model, which allows you to specify how much storage, IOPS, and throughput your file share needs. The amount that you provision determines your total bill. When you create a new file share using the provisioned v2 model, we provide a recommendation for how many IOPS and how much throughput you need based on the amount of provisioned storage you specify. Depending on your requirements, you can choose to override these recommendations with your own values.

  • The Microsoft.FileShares preview only supports locally-redundant storage (LRS) and zone-redundant storage (ZRS). See Azure Files redundancy for more information.

For more information on Azure Files management concepts, see Plan for an Azure Files deployment.

Applies to

Management model Billing model Media tier Redundancy SMB NFS
Microsoft.FileShares Provisioned v2 SSD (premium) Local (LRS) No Yes
Microsoft.FileShares Provisioned v2 SSD (premium) Zone (ZRS) No Yes
Microsoft.Storage Provisioned v2 HDD (standard) Local (LRS) No No
Microsoft.Storage Provisioned v2 HDD (standard) Zone (ZRS) No No
Microsoft.Storage Provisioned v2 HDD (standard) Geo (GRS) No No
Microsoft.Storage Provisioned v2 HDD (standard) GeoZone (GZRS) No No
Microsoft.Storage Provisioned v1 SSD (premium) Local (LRS) No No
Microsoft.Storage Provisioned v1 SSD (premium) Zone (ZRS) No No
Microsoft.Storage Pay-as-you-go HDD (standard) Local (LRS) No No
Microsoft.Storage Pay-as-you-go HDD (standard) Zone (ZRS) No No
Microsoft.Storage Pay-as-you-go HDD (standard) Geo (GRS) No No
Microsoft.Storage Pay-as-you-go HDD (standard) GeoZone (GZRS) No No

Prerequisites

This article assumes that you have an Azure subscription. If you don't have an Azure subscription, then create a free account before you begin.

Make sure both "Microsoft.FileShares" and "Microsoft.Storage" resource providers are registered for the subscription. To register a resource provider, follow these steps.

  1. Sign in to Azure portal.
  2. In the search box, enter subscriptions.
  3. Select the subscription you want to use to register a resource provider.
  4. To see the list of resource providers, under Settings, select Resource providers.
  5. Select the resource provider you intend to add and then select Register.

Create a file share (Microsoft.FileShares)

Note

File share with Microsoft.FileShares is currently in preview. You may use the Azure portal, or you can use generic PowerShell or Azure CLI commands to work with file shares. If you want to try the CLI private package for Microsoft.FileShares resource provider, fill out this survey.

To create a file share via the Azure portal, use the search box at the top of the Azure portal to search for file share and select the matching result.

A screenshot of the Azure portal search box with results for file share.

Select + Create to create a new file share.

A screenshot of the Azure portal for create button for file share.

Basics

The first tab to complete creating a file share is labeled Basics, which contains the required fields to create a file share.

A screenshot of the Azure portal for create flow 1 for file share.

Field name Input type Values Meaning
Subscription Drop-down list Available Azure subscriptions The selected subscription in which to deploy the storage account.
Resource group Drop-down list Available resource groups in selected subscription The resource group in which to deploy the file share. A resource group is a logical container for organizing Azure resources, including file shares.
file share name Text box -- The name of the file share must be unique across all existing file share names in Microsoft Azure. It must be 3 to 63 characters long and can contain only lowercase letters, numbers, and hyphens. The name must start and end with a letter or number.
Tier N/A -- Premium file shares are backed by solid-state drives (SSD) for better performance. Currently, the Microsoft.FileShares preview only supports SSD.
Protocol N/A -- file shares support a multitude of access protocols. If you need the SMB protocol, deploy your file share within a storage account. Currently, the Microsoft.FileShares preview only supports NFS protocol.
Region Drop-down list Available Azure regions The region for the file share to be deployed into. This can be the region associated with the resource group, or any other available region.
Provisioned capacity (GiB) Text box Integer Provisioned capacity for the file share, ranging from 32 GiB to 262144 GiB.
Redundancy Drop-down list - Locally redundant storage (LRS)
- Geo-redundant storage (GRS)
The redundancy choice for the file share. See Azure Files redundancy for more information.
Provisioned IOPS and throughput Radio button group - Recommended provisioning
- Manually specify IOPS and throughput:
    - Provisioned IOPS
    - Provisioned throughput (MiB/sec)
The Microsoft.FileShares preview only uses the provisioned v2 billing model.

Advanced

The Advanced tab is optional and provides more granular settings. You can choose to set up root squash options or specify a mount name for the file share. Mount name allows you to choose a different name to use to mount the file share. By default, it's the same as the file share name. Customize it if you want a unique mount name. The same rules still apply to the naming policy. See Naming rules and restrictions for Azure resources.

A screenshot of the  of the advanced tab.

Networking

Using the NFS protocol for a file share requires network-level security configurations. There are two options for establishing networking-level security configurations: Private endpoint and service endpoint.

A private endpoint gives your file share a private, static IP address within your virtual network, preventing connectivity interruptions from dynamic IP address changes. Traffic to your file share stays within peered virtual networks, including those in other regions and on premises. You can set up a private endpoint after you create the file share. For region support on private endpoints for Microsoft.Fileshares, see Plan to deploy Azure Files.

If you don't require a static IP address, you can enable a service endpoint for Azure Files within the virtual network. A service endpoint configures file share to allow access only from specific subnets. The allowed subnets can belong to a virtual network in the same subscription or a different subscription, including those that belong to a different Microsoft Entra tenant. There's no extra charge for using service endpoints. You can create or choose an existing virtual network for service endpoint purpose in the networking tab during the create flow.

Tags

Tags are name/value pairs that enable you to categorize resources and view consolidated billing by applying the same tag to multiple resources and resource groups. These are optional, and you can apply them after you create the file share.

Review + create

The final step to create the file share is to select the Create button on the Review + create tab. This button isn't available until you complete all the required fields.

Set up a private endpoint

  1. After the file share is created, search for private endpoint in the search bar, and then click on create button.

  2. Leave Subscription and Resource group the same. Under Instance, provide a name and select a region for the new private endpoint. Your private endpoint must be in the same region as your virtual network, so use the same region as you specified when creating the VM. When all the fields are complete, select Next: Resource.

    image for private endpoint creation for mfs part 1

  3. Confirm that the Subscription, and Resource are correct. Choose Microsoft.FileShares/fileShares as the Resource type, and select FileShare from the Target sub-resource drop-down. Then select Next: Virtual Network.

    image for private endpoint creation for mfs part 2

  4. Under Networking, select the virtual network associated with your VM and leave the default subnet. Under Private IP configuration, leave Dynamically allocate IP address selected. Select Next: DNS. Screenshot showing how to add virtual networking and private IP configuration to a new private endpoint.

  5. Select Yes for Integrate with private DNS zone. Make sure the correct subscription and resource group are selected, and then select Next: Tags. Screenshot showing how to integrate your private endpoint with a private DNS zone.

  6. You can optionally apply tags to categorize your resources, such as applying the name Environment and the value Test to all testing resources. Enter name/value pairs if desired, and then select Next: Review + create. Screenshot showing how to add tags to resources in order to categorize them.

  7. Azure will attempt to validate the private endpoint. When validation is complete, select Create. You'll see a notification that deployment is in progress. After a few minutes, you should see a notification that deployment is complete.

Next steps