204k views
1 vote
What PowerShell cmdlet is used to stop a VM? What Azure CLI command is used?

a) Stop-AzVM / az vm stop
b) Shutdown-AzVM / az vm shutdown
c) Pause-AzVM / az vm pause
d) Halt-AzVM / az vm halt

User H Walters
by
8.0k points

1 Answer

1 vote

Final answer:

In Azure, the PowerShell cmdlet to stop a VM is Stop-AzVM, and the Azure CLI command is az vm stop; they deallocate the VM to stop billing for compute resources.

Step-by-step explanation:

The PowerShell cmdlet used to stop a VM in Azure is Stop-AzVM, and the Azure CLI command used is az vm stop. These commands are used to deallocate the VM so that you are not billed for the compute resources that it uses. However, it's important to note that the disks associated with the VM will still incur costs until they are deleted or deallocated separately.

User Reejesh PK
by
7.1k points