Azure VM Automation

Axel Sch 0 Reputation points
2025-03-13T12:49:19.4566667+00:00

aziure VM automation Task Start VM fails with infalid connection can this be due to the user with 2 factor authentication

But Tenat ID the RG and the VM Name are rigth

grafik

Azure Automation
Azure Automation
An Azure service that is used to automate, configure, and install updates across hybrid environments.
1,328 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Naveena Patlolla 975 Reputation points Microsoft External Staff
    2025-03-13T16:33:28.0466667+00:00

    Hi Axel Sch

    https://learn.microsoft.com/en-us/azure/automation/enable-managed-identity-for-automation#enable-using-the-azure-portal

    Enable Managed Identity for your Azure Automation Account:

    System-assigned Managed Identity:

    In the Azure portal, navigate to your Automation Account.

    Go to "Identity" under "Account Settings."

    Set "System assigned" to "On."

    Click "Save."

    Azure will create a managed identity associated with your Automation Account.

    Grant Permissions to the Managed Identity:

    Your Automation Account's managed identity needs appropriate permissions to access the Azure resources your runbook will interact with.

    For example, if your runbook needs to start a virtual machine:

    Navigate to the virtual machine in the Azure portal.

    Go to "Access control (IAM)."

    Click "Add" > "Add role assignment."

    Select the appropriate role (e.g., "Virtual Machine Contributor").

    In "Assign access to," choose "Managed identity."

    Select "Automation Account" and then your Automation Account's name.

    Click "Save."

    Please do not forget to "Accept the answer” and “upvote it” wherever the information provided helps you, this can be beneficial to other community members.it would be greatly appreciated and helpful to others.

    0 comments No comments

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.