Getting "the resource identity associated with policy assignment can not be found" during remediation

asked 2021-11-02T20:57:39.467+00:00
Gregory Suvalian 176 Reputation points

I have policy which is using modify effect. I use user assigned identity during assignment which lives in different subscription but under the same tenant. Assignment completes successfully but policy enforcement fails with error below. Identity itself works fine for various other tasks (like logic apps etc)

Failed to remediate resource: '/subscriptions/032702ff-a599-4aeb-b906-41f6e8f8dd28/resourceGroups/test-rg/providers/Microsoft.Compute/virtualMachines/test'. The 'PATCH' request failed with status code: 'BadRequest'. Inner Error: 'The resource identity associated with policy assignment '/providers/Microsoft.Management/managementGroups/thc-sandbox-mg/providers/Microsoft.Authorization/policyAssignments/ea197105e4a947c6b2a87d6f' can not be found. It may have been manually removed in Azure Active Directory. Please see https://aka.ms/arm-policy-identity for managed identity usage details.', Correlation Id: '<null>'.

Azure Policy
Azure Policy
An Azure service that is used to implement corporate governance and standards at scale for Azure resources.
506 questions
No comments
{count} votes

Accepted answer
  1. answered 2021-11-05T20:03:07.137+00:00
    Gregory Suvalian 176 Reputation points

    Per request from Microsoft, I reassigned the same policy and it started working


0 additional answers

Sort by: Most helpful