Skip to content

Commit 3606540

Browse files
authored
Merge pull request #200223 from brittanyrowe/adh-restart
Restart Client Tooling Updates
2 parents 3e5153d + 5177371 commit 3606540

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

articles/virtual-machines/dedicated-hosts-how-to.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -614,6 +614,50 @@ Tags : {}
614614

615615
---
616616

617+
## Restart a host (Preview)
618+
619+
You can restart the entire host, meaning that the host's not **completely** powered off. Because the host will be restarted, the underlying VMs will also be restarted. The host will remain on the same underlying physical hardware as it restarts and both the host ID and asset ID will remain the same after the restart. The host SKU will also remain the same after the restart.
620+
621+
Note: Host restart is in preview.
622+
623+
### [Portal](#tab/portal)
624+
1. Search for and select the host.
625+
1. In the top menu bar, select the **Restart** button. Note, this feature is in Preview.
626+
1. In the **Essentials** section of the Host Resource Pane, Host Status will switch to **Host undergoing restart** during the restart.
627+
1. Once the restart has completed, the Host Status will return to **Host available**.
628+
629+
### [CLI](#tab/cli)
630+
631+
Restart the host using [az vm host restart](/cli/azure/vm#az-vm-host-restart) (Preview).
632+
633+
```azurecli-interactive
634+
az vm host restart --resource-group myResourceGroup --host-group myHostGroup --name myDedicatedHost
635+
```
636+
637+
To view the status of the restart, you can use the [az vm host get-instance-view](/cli/azure/vm#az-vm-host-get-instance-view) command. The **displayStatus** will be set to **Host undergoing restart** during the restart. Once the restart has completed, the displayStatus will return to **Host available**.
638+
639+
```azurecli-interactive
640+
az vm host get-instance-view --resource-group myResourceGroup --host-group myHostGroup --name myDedicatedHost
641+
```
642+
643+
### [PowerShell](#tab/powershell)
644+
645+
Restart the host using the [Restart-AzHost](/powershell/module/az.compute/restart-azhost) (Preview) command.
646+
647+
```azurepowershell-interactive
648+
Restart-AzHost -ResourceGroupName myResourceGroup -HostGroupName myHostGroup -Name myDedicatedHost
649+
```
650+
651+
To view the status of the restart, you can use the [Get-AzHost](/powershell/module/az.compute/get-azhost) commandlet using the **InstanceView** parameter. The **displayStatus** will be set to **Host undergoing restart** during the restart. Once the restart has completed, the displayStatus will return to **Host available**.
652+
653+
654+
```azurepowershell-interactive
655+
$hostRestartStatus = Get-AzHost -ResourceGroupName myResourceGroup -HostGroupName myHostGroup -Name myDedicatedHost -InstanceView;
656+
$hostRestartStatus.InstanceView.Statuses[1].DisplayStatus;
657+
```
658+
659+
---
660+
617661
## Deleting a host
618662

619663

0 commit comments

Comments
 (0)