Get standby pool and instance details
A standby pool is a dynamic resource that stays in sync with your scale set as your workload scales up and down. This article discusses how to retrieve various information about your standby pool and the instances within it.
Standby pool details
Use the standby pool runtime view APIs to get the current status of your standby pool including how many instances are available, the provisioning state, and what zones are being utilized.
az standby-vm-pool status --resource-group myResourceGroup --name myStandbyPool
{
"id": "/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.StandbyPool/standbyVirtualMachinePools/myStandbyPool/runtimeViews/latest",
{
"zone": 1
},
"instanceCountsByState": [
{
"count": 5,
"state": "Creating"
},
{
"count": 0,
"state": "Starting"
},
{
"count": 5,
"state": "Running"
},
{
"count": 0,
"state": "Deallocating"
},
{
"count": 10,
"state": "Deallocated"
},
{
"count": 0,
"state": "Deleting"
}
],
"zone": 2
},
{
"instanceCountsByState": [
{
"count": 0,
"state": "Creating"
},
{
"count": 10,
"state": "Starting"
},
{
"count": 0,
"state": "Running"
},
{
"count": 5,
"state": "Deallocating"
},
{
"count": 5,
"state": "Deallocated"
},
{
"count": 0,
"state": "Deleting"
}
],
"zone": 3
},
{
"instanceCountsByState": [
{
"count": 0,
"state": "Creating"
},
{
"count": 0,
"state": "Starting"
},
{
"count": 5,
"state": "Running"
},
{
"count": 10,
"state": "Deallocating"
},
{
"count": 3,
"state": "Deallocated"
},
{
"count": 5,
"state": "Deleting"
}
],
"name": "latest",
"provisioningState": "Succeeded",
"resourceGroup": "myResourceGroup",
"type": "Microsoft.StandbyPool/standbyVirtualMachinePools/runtimeViews"
}
Instance details
When a virtual machine is in a standby pool, the isVmInStandbyPool
parameter is set to true. When the virtual machine is moved from the pool instance the scale set, the parameter is automatically updated to false. This can be useful in determining when a virtual machine is ready to receive traffic or not.
az vm get-instance-view --resource-group myResourceGroup --name myVM
"extensions": null,
"hyperVGeneration": "V2",
"isVmInStandbyPool": true,
"maintenanceRedeployStatus": null,
"statuses": [
{
"code": "ProvisioningState/succeeded",
"displayStatus": "Provisioning succeeded",
"level": "Info",
"message": null,
"time": "2024-08-02T17:22:46.295536+00:00"
},
{
"code": "PowerState/deallocated",
"displayStatus": "VM deallocated",
"level": "Info",
"message": null,
"time": null
}
],
Next steps
Review the most frequently asked questions about standby pools for Virtual Machine Scale Sets.