Skip to main content

dedicated_hosts

Creates, updates, deletes, gets or lists a dedicated_hosts resource.

Overview

Namededicated_hosts
TypeResource
Idazure.compute.dedicated_hosts

Fields

NameDatatypeDescription
idtextResource Id
nametextResource name
auto_replace_on_failuretextfield from the properties object
hostGroupNametextfield from the properties object
hostNametextfield from the properties object
host_idtextfield from the properties object
instance_viewtextfield from the properties object
license_typetextfield from the properties object
locationtextResource location
platform_fault_domaintextfield from the properties object
provisioning_statetextfield from the properties object
provisioning_timetextfield from the properties object
resourceGroupNametextfield from the properties object
skutextDescribes a virtual machine scale set sku. NOTE: If the new VM SKU is not supported on the hardware the scale set is currently on, you need to deallocate the VMs in the scale set before you modify the SKU name.
subscriptionIdtextfield from the properties object
tagstextResource tags
time_createdtextfield from the properties object
typetextResource type
virtual_machinestextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECThostGroupName, hostName, resourceGroupName, subscriptionIdRetrieves information about a dedicated host.
list_by_host_groupSELECThostGroupName, resourceGroupName, subscriptionIdLists all of the dedicated hosts in the specified dedicated host group. Use the nextLink property in the response to get the next page of dedicated hosts.
create_or_updateINSERThostGroupName, hostName, resourceGroupName, subscriptionId, data__skuCreate or update a dedicated host .
deleteDELETEhostGroupName, hostName, resourceGroupName, subscriptionIdDelete a dedicated host.
updateUPDATEhostGroupName, hostName, resourceGroupName, subscriptionIdUpdate a dedicated host .
redeployEXEChostGroupName, hostName, resourceGroupName, subscriptionIdRedeploy the dedicated host. The operation will complete successfully once the dedicated host has migrated to a new node and is running. To determine the health of VMs deployed on the dedicated host after the redeploy check the Resource Health Center in the Azure Portal. Please refer to https://docs.microsoft.com/azure/service-health/resource-health-overview for more details.
restartEXEChostGroupName, hostName, resourceGroupName, subscriptionIdRestart the dedicated host. The operation will complete successfully once the dedicated host has restarted and is running. To determine the health of VMs deployed on the dedicated host after the restart check the Resource Health Center in the Azure Portal. Please refer to https://docs.microsoft.com/azure/service-health/resource-health-overview for more details.

SELECT examples

Lists all of the dedicated hosts in the specified dedicated host group. Use the nextLink property in the response to get the next page of dedicated hosts.

SELECT
id,
name,
auto_replace_on_failure,
hostGroupName,
hostName,
host_id,
instance_view,
license_type,
location,
platform_fault_domain,
provisioning_state,
provisioning_time,
resourceGroupName,
sku,
subscriptionId,
tags,
time_created,
type,
virtual_machines
FROM azure.compute.vw_dedicated_hosts
WHERE hostGroupName = '{{ hostGroupName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new dedicated_hosts resource.

/*+ create */
INSERT INTO azure.compute.dedicated_hosts (
hostGroupName,
hostName,
resourceGroupName,
subscriptionId,
data__sku,
properties,
sku,
location,
tags
)
SELECT
'{{ hostGroupName }}',
'{{ hostName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ data__sku }}',
'{{ properties }}',
'{{ sku }}',
'{{ location }}',
'{{ tags }}'
;

UPDATE example

Updates a dedicated_hosts resource.

/*+ update */
UPDATE azure.compute.dedicated_hosts
SET
properties = '{{ properties }}',
sku = '{{ sku }}',
tags = '{{ tags }}'
WHERE
hostGroupName = '{{ hostGroupName }}'
AND hostName = '{{ hostName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified dedicated_hosts resource.

/*+ delete */
DELETE FROM azure.compute.dedicated_hosts
WHERE hostGroupName = '{{ hostGroupName }}'
AND hostName = '{{ hostName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';