Raw New Markdown
Generating updated version of doc...
Rendered New Markdown
Generating updated version of doc...
---
title: Using Run Command in Azure VMware Solution
description: Learn about using Run Commands in Azure VMware Solution.
ms.topic: how-to
ms.service: azure-vmware
ms.date: 3/22/2024
ms.custom: engagement-fy23
# Customer intent: As a cloud administrator, I want to use Run Command in Azure VMware Solution, so that I can perform operations that typically require elevated privileges efficiently and manage my virtual environment effectively.
---
# Run Command in Azure VMware Solution
In Azure VMware Solution, vCenter Server has a built-in local user called *cloudadmin* assigned to the CloudAdmin role. The CloudAdmin role has vCenter Server [privileges](architecture-identity.md#vcenter-server-access-and-identity) that differ from other VMware cloud solutions and on-premises deployments. The Run Command feature lets you perform operations that would normally require elevated privileges through a collection of PowerShell cmdlets.
Azure VMware Solution supports the following operations:
- [Configure an external identity source](configure-identity-source-vcenter.md)
- [View and set storage policies](configure-storage-policy.md)
- [Deploy disaster recovery using JetStream](deploy-disaster-recovery-using-jetstream.md)
- [Use VMware HCX Run Commands](use-hcx-run-commands.md)
>[!NOTE]
>Run Commands are executed one at a time in the order submitted.
## View the status of an execution
You can view the status of any executed Run Command, including the output, errors, warnings, and information logs of the cmdlets.
1. Sign in to the [Azure portal](https://portal.azure.com).
>[!NOTE]
>If you need access to the Azure US Gov portal, go to https://portal.azure.us/
1. Select **Run command** > **Run execution status**.
You can sort by the various columns by selecting the column.
:::image type="content" source="media/run-command/run-execution-status.png" alt-text="Screenshot showing Run Command execution status tab." lightbox="media/run-command/run-execution-status.png":::
1. Select the execution you want to view. A pane opens with details about the execution, and other tabs for the various types of output generated by the cmdlet.
:::image type="content" source="media/run-command/run-execution-status-example.png" alt-text="Screenshot showing an example of a run execution.":::
You can view more details about the execution including the output, errors, warnings, and information.
- **Details** - Summary of the execution details, such as the name, status, package, cmdlet name, and error if the command failed.
- **Output** - Messages output by the cmdlet can include progress or the result of the operation. Not all cmdlets have output.
:::image type="content" source="media/run-command/run-execution-status-example-output.png" alt-text="Screenshot showing the output of a run execution.":::
- **Error** - Error messages generated in the execution of the cmdlet in addition to the terminating error message on the details pane.
:::image type="content" source="media/run-command/run-execution-status-example-error.png" alt-text="Screenshot showing the errors detected during the execution of an execution.":::
- **Warning** - Warning messages generated during the execution.
:::image type="content" source="media/run-command/run-execution-status-example-warning.png" alt-text="Screenshot showing the warnings detected during the execution of an execution.":::
- **Information** - Progress and diagnostic generated messages during the execution of a cmdlet.
:::image type="content" source="media/run-command/run-execution-status-example-information.png" alt-text="Screenshot showing the overall real-time progress of the cmdlet as it runs.":::
## Cancel or delete a job
### Method 1
This method attempts to cancel the execution, and then deletes it upon completion.
>[!IMPORTANT]
>Method 1 is irreversible.
1. Select **Run command** > **Run execution status** and then select the job you want to cancel.
:::image type="content" source="media/run-command/run-execution-cancel-delete-job-method-1.png" alt-text="Screenshot showing how to cancel and delete a run command.":::
2. Select **Yes** to cancel and remove the job for all users.
### Method 2
1. Select **Run command** > **Packages** > **Run execution status**.
2. Select **More** (...) for the job you want to cancel and delete.
:::image type="content" source="media/run-command/run-execution-cancel-delete-job-method-2.png" alt-text="Screenshot showing how to cancel and delete a run command using the ellipsis.":::
3. Select **Yes** to cancel and remove the job for all users.
## Next steps
Now that you've learned about the Run Command concepts, you can use the Run Command feature to:
- [Configure storage policy](configure-storage-policy.md) - Each VM deployed to a vSAN datastore is assigned a vSAN storage policy. You can assign a vSAN storage policy in an initial deployment of a VM or when you do other VM operations, such as cloning or migrating.
- [Configure external identity source for vCenter Server (Run Command)](configure-identity-source-vcenter.md) - Configure Active Directory over LDAP or LDAPS for vCenter Server, which enables the use of an external identity source as an Active Directory. Then, you can add groups from the external identity source to the CloudAdmin role.
- [Deploy disaster recovery using JetStream](deploy-disaster-recovery-using-jetstream.md) - Store data directly to a recovery cluster in vSAN. The data gets captured through I/O filters that run within vSphere. The underlying vSphere datastore can be VMFS, vSAN, vVol, or any supported HCI platform.