Task 02 - Validate Resource providers
Description
In this task, you will ensure that all the needed Resource providers that will be need in the next tasks are registered on your subscription.
Success Criteria
- You have validated all the necessary Resource providers.
Solution
Expand this section to view the solution
-
Sign in to the Azure Portal.
If you’re using Azure Gov, sign in to the Azure Gov Portal.
-
At the top of the Azure Portal, select the Cloud Shell icon.
-
In the Cloud Shell, run the following Azure CLI command. This will retrieve the registration status for all the Resource providers needed during the exercises.
az provider show --namespace 'Microsoft.Network' -o table; az provider show --namespace 'Microsoft.Sql' -o table; az provider show --namespace 'Microsoft.Storage' -o table; az provider show --namespace 'Microsoft.Compute' -o table; az provider show --namespace 'Microsoft.DataMigration' -o table
Example output:
Namespace RegistrationPolicy RegistrationState ----------------- -------------------- ------------------- Microsoft.Network RegistrationRequired Registered Namespace RegistrationPolicy RegistrationState ------------- -------------------- ------------------- Microsoft.Sql RegistrationRequired Registered Namespace RegistrationPolicy RegistrationState ----------------- -------------------- ------------------- Microsoft.Storage RegistrationRequired Registered Namespace RegistrationPolicy RegistrationState ----------------- -------------------- ------------------- Microsoft.Compute RegistrationRequired Registered Namespace RegistrationPolicy RegistrationState ----------------------- -------------------- ------------------- Microsoft.DataMigration RegistrationRequired NotRegistered
-
Take note of all the Namespace values that have a RegistrationState of
NotRegistered
. -
For each of the values retrieved previously, run the following Azure CLI command. This will register the specified Resource provider.
az provider register --namespace 'PROVIDER' --wait
Example command to register the
Microsoft.DataMigration
provider:az provider register --namespace 'Microsoft.DataMigration' --wait
-
Copy the id and userPrincipalName values from the returned output from the Azure CLI command and save it for use later.
The ARM Template will use this user Id and Name as the Administrator for the Azure SQL Managed Instance resource. This user must be an Entra ID user and cannot be a personal Microsoft Account. If you need to, look up an alternative user to use for this, then run the following command instead:
az ad user show --id <azure-login>
Replace the
<azure-login>
placeholder with the user’s email login. Ex:user@domain.onmicrosoft.com