Not authorized to create a VM

Neil Siregar 20 Reputation points
2024-01-11T02:37:13.6433333+00:00

(AuthorizationFailed) The client '@leonardo.com.au' with object id 'd949c9f8-4d66-4559-a3cd-fb0b8cea3f22' does not have authorization to perform action 'Microsoft.Resources/subscriptions/resourcegroups/read' over scope '/subscriptions/f27a2135-1ae7-44b2-b514-f0b7b1dcbfba/resourcegroups/my-resource-group' or the scope is invalid. If access was recently granted, please refresh your credentials. Code: AuthorizationFailed Message: The client '@leonardo.com.au' with object id 'd949c9f8-4d66-4559-a3cd-fb0b8cea3f22' does not have authorization to perform action 'Microsoft.Resources/subscriptions/resourcegroups/read' over scope '/subscriptions/f27a2135-1ae7-44b2-b514-f0b7b1dcbfba/resourcegroups/my-resource-group' or the scope is invalid. If access was recently granted, please refresh your credentials.

Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
2,073 questions
0 comments No comments
{count} votes

Accepted answer
  1. TP 103.7K Reputation points
    2024-01-11T03:28:42.64+00:00

    Hi Neil,

    The script you are entering isn't correct. There is no resource group "my-resource-group" and you don't have permission to create it. There is a bug in the exercise. You may use instructions below as a workaround.

    Please navigate to the Create an Azure virtual machine exercise, Activate a new sandbox, sign in, etc. Once sandbox is activated and black cloud shell window with "Welcome to Azure Cloud Shell" displayed, navigate to Exercise - Configure network access using the "Unit x of 14" dropdown above the exercise.

    qna az-900 create azure vm workaround

    After page loads and resource group name is updated to learn-, immediately navigate back to Create an Azure virtual machine exercise and complete it. Inspiration for above workaround came from @pnaroju's #2 suggestion in this post.

    Please click Accept Answer and upvote if the above was helpful.

    Thanks.

    -TP

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.