Create Custom Role

Juan Pablo Delgadillo Martinez 66 Reputation points
2024-11-05T19:41:33.17+00:00

I have the following error when creating a custom role:

with object id 26f83ad1-0683-493e-a0f1-fceSfc67332* does not have authorization to perform action Microsoft. Authorization/roleDefinitions/write over scope /providers/Microsoft.Authorization/roleDefinitions/subscription or the scope is invalid. If access was recently

cranted, please retrech vour credentials.

I am the owner of the portal and it does not allow me to create these roles even if they are basic roles like "Microsoft.Storage/*/read", it does not allow me to add them

Azure Role-based access control
Azure Role-based access control
An Azure service that provides fine-grained access management for Azure resources, enabling you to grant users only the rights they need to perform their jobs.
843 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
22,514 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Andy David - MVP 150.5K Reputation points MVP
    2024-11-05T19:58:47.4933333+00:00

    Check your role access against one of the subscriptions.

    https://learn.microsoft.com/en-us/azure/role-based-access-control/check-access

    0 comments No comments

  2. Navya 13,455 Reputation points Microsoft Vendor
    2024-11-05T20:19:55.6333333+00:00

    Hi @Juan Pablo Delgadillo Martinez

    Thank you for posting this in Microsoft Q&A.

    I understand that you are creating Azure custom roles but are encountering an authorization error.

    To create Azure custom roles, you need either the Owner or User Access Administrator role.

    As you mentioned, you are the owner of the portal. However, please ensure that your account has the necessary permissions to create custom roles.

    Make sure you are attempting to create the role at the correct scope. The error message suggests that the scope you are using may be invalid or that you lack permissions for it.

    https://learn.microsoft.com/en-us/azure/role-based-access-control/custom-roles-portal

    If you are still encountering issues, please try creating the custom role using Azure PowerShell or Azure CLI instead of the Azure portal.

    For your reference:
    https://learn.microsoft.com/en-us/azure/role-based-access-control/custom-roles-powershell
    https://learn.microsoft.com/en-us/azure/role-based-access-control/custom-roles-cli

    Hope this helps. Do let us know if you any further queries.

    Thanks,

    Navya.


    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


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.