Virtual Machines - Redeploy
Action to redeploy a lab virtual machine to a different compute node. For troubleshooting connectivity.
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.LabServices/labs/{labName}/virtualMachines/{virtualMachineName}/redeploy?api-version=2023-06-07
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
lab
|
path | True |
string minLength: 1maxLength: 100 |
The name of the lab that uniquely identifies it within containing lab plan. Used in resource URIs. |
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
The name of the resource group. The name is case insensitive. |
|
subscription
|
path | True |
string minLength: 1 |
The ID of the target subscription. |
|
virtual
|
path | True |
string minLength: 1maxLength: 100 pattern: ^[-\w\\._\\(\\)]+$ |
The ID of the virtual machine that uniquely identifies it within the containing lab. Used in resource URIs. |
|
api-version
|
query | True |
string minLength: 1 |
The API version to use for this operation. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
The request was completed. |
|
| 202 Accepted |
The request was accepted. |
|
| Other Status Codes |
The default error response. |
Examples
redeployVirtualMachine
Sample request
POST https://management.azure.com/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.LabServices/labs/testlab/virtualMachines/template/redeploy?api-version=2023-06-07
Sample response
Location: https://management.azure.com/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/providers/Microsoft.LabServices/operationresults/a64149d8-84cb-4566-ab8e-b4ee1a074174
Definitions
| Name | Description |
|---|---|
|
Error |
The resource management error additional info. |
|
Error |
The error detail. |
|
Error |
Error response |
ErrorAdditionalInfo
The resource management error additional info.
| Name | Type | Description |
|---|---|---|
| info |
object |
The additional info. |
| type |
string |
The additional info type. |
ErrorDetail
The error detail.
| Name | Type | Description |
|---|---|---|
| additionalInfo |
The error additional info. |
|
| code |
string |
The error code. |
| details |
The error details. |
|
| message |
string |
The error message. |
| target |
string |
The error target. |
ErrorResponse
Error response
| Name | Type | Description |
|---|---|---|
| error |
The error object. |