One-Click Deployment for Azure NetApp Files (ANF)


Azure NetApp Files (ANF for short) is no longer so new and has already proven in various projects where the advantages of this enterprise storage is.

In this blog entry, I want to talk less about the Use Cases. But give the proof-of-concept (PoC in short) the ability to simplify the ANF deployment,
or via Powershell. Of course, you can do everything as usual via the Azure Portal (

I have become accustomed to deploying ANF into the customer’s environment via Powershell for various PoC’s. For this reason, I would like to use my Powershellscript here for and explain in part.

Basic requirements

  1. The first requirement to use ANF is to register the subscription for ANF. You can find the information in this article:
  2. Next, you should familiarize yourself with the documentation of ANF. Information can be found here:
  3. The next step is to download my Powershell Script from Github. You can find the script here:

The Script

Before we start the deployment a few words to the script.

The script expects various paramters for the deployment, which are requested after start. Things like Location, ResourceGroup Name, VNet & Subnet are queried.
With this script, an ANF account, pool & volume with all associated resources is deployed in the West Europe & North Europe region. You can also use
Snapshots for an existing volume. If you want to deploy ANF only in one region, you can deactivate the lines in the script for the 2nd region.

More Parameters

There are various parameters which I have entered firmly, but which can also be changed or adjusted as required.

more parameters anf azure netapp files

Install Modules

Later, the script checks whether all necessary Az Powershell modules are available and are up to date. If not, they will be downloaded and installed.

install module anf azure netapp files

Connect to Azure

The next step is to connect to Azure and the subscription.

connect to azure anf azure netapp files

ANF Deployment

The next block deploys the ANF and dependent resources, even in the 2nd location.

first location anf azure netapp files

second location anf azure netapp files

If desired, a snapshot of a volume can still be performed.

snapshot anf azure netapp files

Delete Resources

Once all the resources have been deployed, there will be costs.
So if this is not desired, simply delete the voluem. or the entire Resource Group.

delete resources anf azure netapp files

Either you start the script block by block, or alternatively you can start one line of Powershell and specify the individual parameter values after the script.

For the deployment in one region

.\ANF-PoC-Deployment.ps1 -location westeurope -resourcegroup anfwe – anfaccountname anfwe -creationtoken anfwetest -subnetaddressprefix -networkaddressprefix

Other Deployment method

For the deployment in two regions

.\ANF-PoC-Deployment.ps1 -location westeurope -resourcegroup anfwe – anfaccountname anfwe -creationtoken anfwetest -subnetaddressprefix -networkaddressprefix -secondlocation northeurope -secondresourcegroup anfne – secondanfaccountname anfne -secondcreationtoken anfnetest -secondsubnetaddressprefix -secondnetworkaddressprefix

The End

There is certainly a lot to improve on the script, but I’m constantly working on it.
Next I would try a deployment via ARM Templates.

For more infromation about the Use Cases use this Link:

Hashtags: #AzureNetAppFiles #Azure #cloudmigration #datacenters #storage #data #cloudstorage #hybridcloud #NetApp #Microsoft #workloads #applications

Azure Powershell Anmeldung über ein weiteres Script aus dem Hintergrund starten

Wie bekommt man PowerShell Skripte sicher und automatisch für den Zugriff auf die Azure Subscription zur Ausführung?

Da hilft dieses kleine Powershellscript:

$username = "deinADAccount" #Azure AD User Account
$password = ConvertTo-SecureString "deinPasswort" -AsPlainText -Force 
$cred = new-object -typename System.Management.Automation.PSCredential -argumentlist $username, $password Add-AzureAccount -Credential $cred
Login-AzureRmAccount $cred

Dieses Script legst Du als “Login_to_Azure.ps1” an einen sicheren Ort auf deiner Platte. In den weiteren Powershellscripten verweist Du einfach auf dieses Script.
z.B. mit:

#Login Azure Account 

Bei der Beschreibung in diesem Beitrag legst du dein Passwort im Klartext ab. Das ist bestimmt nicht sicher, aber ein Einstieg.

In einem weiteren Beitrag werde ich eine sicherere Variante erläutern.