skip to Main Content

I’m working through some tutorials, and after successfully creating a resource group, I cannot create a corresponding storage account.

az login

Cmd to create resource group:

az group create --location "Central US" --name <my_resource_group_name>

This runs with "provisioningState": "Succeeded"

Cmd to create account storage:

az storage create --name "some_name" --resource-group <my_resource_group_name> 

This fails with (SubscriptionNotFound)

Subscription <my_subscription_id> was not found.
Code: SubscriptionNotFound
Message: Subscription <my_subscription_id> was not found.

Is the tutorial missing a step in between? Azure is obviously ‘finding’ my subscription id, but I’m not sure what else is causing the error.

2

Answers


  1. It appears somehow the correct command from the source github.com was not used. The command should be az storage account create. You seemed to have used az storage create. obviously, you missed the account part of the Azure CLI command.

     az storage account create --name "azst112345667anthony" --resource-group "Test" 
    

    Note the naming convention you cannot use special characters please check here https://learn.microsoft.com/en-us/azure/storage/common/storage-account-overview.

    1. Storage account names must be between 3 and 24 characters in length
      and may contain numbers and lowercase letters only.

    2. Your storage account name must be unique within Azure. No two
      storage accounts can have the same name.

    Example: command will correctly work as below.
    enter image description here

    Login or Signup to reply.
  2. Subscription <my_subscription_id> was not found.
    Code: SubscriptionNotFound
    Message: Subscription <my_subscription_id> was not found.

    The above error occurs when Microsoft.Storage Resource Provider is not registered for the subscription.

    Portal:

    Portal-> < Your-Subscription> -> Resource providers -> search Microsoft. Storage -> Register.

    enter image description here

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search