Create an Azure Files Share
This article guides you through the process of creating a new Azure Files share, a fully managed cloud file share accessible via the industry-standard Server Message Block (SMB) protocol and Network File System (NFS) protocol.
Prerequisites
Before you begin, ensure you have the following:
- An Azure subscription. If you don't have one, create a free account.
- An Azure Storage account. If you don't have one, you can create one following the Azure Storage account creation guide.
Steps to Create an Azure Files Share
You can create an Azure Files share using the Azure portal, Azure CLI, PowerShell, or Azure Storage SDKs. This guide focuses on the Azure portal for ease of use.
Using the Azure Portal
Step 1: Navigate to your Storage Account
Sign in to the Azure portal. In the search bar at the top, type "Storage accounts" and select it. Choose the storage account where you want to create the file share.
Step 2: Access File Shares Blade
In your storage account's overview page, under the "Data storage" section in the left-hand menu, select File shares.
Step 3: Create a New File Share
Click the + File share button at the top of the File shares page.
Step 4: Configure File Share Settings
A blade will appear to configure your new file share:
- Name: Enter a unique name for your file share. Share names must be lowercase letters and numbers.
- Tier: Select the appropriate performance tier:
- Transaction optimized: Default, suitable for most workloads.
- Hot: For frequently accessed data.
- Cool: For infrequently accessed data.
- Capacity: Specify the maximum size of the file share in GiB.
- Enabled protocols: Choose between SMB and NFS. SMB is the default.
Click Create to provision your new file share.
Step 5: Verify Creation
Once the file share is created, it will appear in the list of file shares for your storage account. You can now proceed to mount or access it.
Using Azure CLI
Use the following Azure CLI command to create a file share:
az storage share create \
--name \
--account-name \
--account-key \
--quota \
--output table
Replace the placeholders with your actual values:
<YOUR_FILE_SHARE_NAME>: The desired name for your file share.<YOUR_STORAGE_ACCOUNT_NAME>: The name of your Azure Storage account.<YOUR_STORAGE_ACCOUNT_KEY>: The access key for your storage account. You can retrieve this from the storage account's "Access keys" blade in the Azure portal.<SIZE_IN_GIB>: The desired capacity in GiB (e.g., 1024 for 1 TiB).
For more advanced options, including specifying the tier, refer to the Azure CLI documentation for az storage share create.
Using Azure PowerShell
Use the following Azure PowerShell command to create a file share:
New-AzStorageShare -Name "" -Context (Get-AzStorageAccount -ResourceGroupName "" -AccountName "").Context -CapacityGB
Replace the placeholders with your actual values:
<YOUR_FILE_SHARE_NAME>: The desired name for your file share.<YOUR_RESOURCE_GROUP_NAME>: The resource group your storage account belongs to.<YOUR_STORAGE_ACCOUNT_NAME>: The name of your Azure Storage account.<SIZE_IN_GIB>: The desired capacity in GiB (e.g., 1024 for 1 TiB).
For more advanced options, including specifying the tier, refer to the Azure PowerShell documentation for New-AzStorageShare.