nerdexam
Microsoft

AZ-104 · Question #474

You have an Azure virtual machine (VM) that has a single data disk. You have been tasked with attaching this data disk to another Azure VM. You need to make sure that your strategy allows for the…

The correct answer is C. Detach the data disk. You can simply detach a data disk from one VM and attach it to the other VM without stopping either of the VMs. When you no longer need a data disk that's attached to a virtual machine, you can easily detach it. This removes the disk from the virtual machine, but doesn't remove…

Submitted by yasin.bd· Mar 4, 2026Implement and manage Azure compute resources

Question

You have an Azure virtual machine (VM) that has a single data disk. You have been tasked with attaching this data disk to another Azure VM. You need to make sure that your strategy allows for the virtual machines to be offline for the least amount of time possible. Which of the following is the action you should take FIRST?

Options

  • AStop the VM that includes the data disk.
  • BStop the VM that the data disk must be attached to.
  • CDetach the data disk.
  • DDelete the VM that includes the data disk.

How the community answered

(46 responses)
  • A
    15% (7)
  • B
    2% (1)
  • C
    76% (35)
  • D
    7% (3)

Explanation

You can simply detach a data disk from one VM and attach it to the other VM without stopping either of the VMs. When you no longer need a data disk that's attached to a virtual machine, you can easily detach it. This removes the disk from the virtual machine, but doesn't remove it from storage. When you detach the disk, make sure nothing is actively using the disk before detaching it from the VM. You can detach a disk using PowerShell. https://learn.microsoft.com/en-us/azure/virtual-machines/windows/detach-disk

Community Discussion

No community discussion yet for this question.

Full AZ-104 Practice