Courseiva
Deploy and Manage Azure ComputeeasyMultiple ChoiceObjective-mapped

AZ-104 Deploy and Manage Azure Compute Practice Question

A data disk was accidentally deleted from a VM. You have a snapshot of that disk from before the deletion. What should you create first to restore the data with minimal impact to the VM's OS disk?

⚠ Common exam trap

Many candidates think they need to recreate the entire VM (Option B) to use the snapshot, not realizing that a snapshot can be converted directly into a managed disk and attached to the existing VM without any OS disk impact.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

A new managed disk from the snapshot

A is correct because creating a new managed disk from the snapshot is the direct and minimal-impact method to restore the deleted data disk. Once the new managed disk is created, you can attach it to the existing VM without affecting the OS disk or requiring a VM rebuild. This approach avoids any downtime beyond the brief attachment operation.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • A new managed disk from the snapshot

    Why this is correct

    A snapshot is a backup point for a disk, but it must be turned into a managed disk before it can be attached to a VM. Creating a new managed disk from the snapshot restores the data in a recoverable form while leaving the VM's OS disk untouched. After the new disk is created, you can attach it as a data disk. This is the normal restore path for a deleted or lost managed data disk.

  • A new virtual machine

    Why it's wrong here

    Creating a new virtual machine to address a single deleted data disk is an excessively broad and indirect action. A fresh VM would be empty (or use its own OS disk) and would not automatically contain the data from the deleted disk unless you also create a managed disk from the snapshot and attach it to that new VM. This approach incurs unnecessary compute cost, time, and configuration overhead; the correct restore path is to create a managed disk from the snapshot and attach it to the existing VM, preserving the original VM without rebuilding it.

    When this WOULD be correct

    If the original VM is corrupted or deleted, and you need to restore the entire VM (including OS and data disks) from a snapshot, you would create a new VM from the snapshot. For example, when the VM itself is lost and you have a VM-level snapshot.

  • A new availability set

    Why it's wrong here

    An availability set is a logical grouping of VMs that Azure places across distinct fault domains and update domains to protect against hardware failures and maintenance downtime. It is purely a high-availability construct and has no relationship to the storage plane, so creating one does not recreate the deleted disk's data or restore any snapshot. To recover the lost data disk, you must create a managed disk from the existing snapshot and attach it to the VM—an availability set provides no recovery mechanism for disk contents.

    When this WOULD be correct

    When deploying two or more VMs that must remain available during planned or unplanned maintenance, you would create an availability set to ensure they are placed on different fault and update domains.

  • A larger VM size

    Why it's wrong here

    Resizing a VM to a larger size changes its SKU, increasing vCPUs, memory, and potentially network bandwidth, but it operates entirely in the compute plane. The resizing process does not access, restore, or reattach any deleted storage resources; the data disk remains permanently lost unless a snapshot is used. In fact, resizing may require the VM to be stopped and restarted, and it has no effect on snapshots or disk recovery—the only way to recover the deleted disk is to create a managed disk from the snapshot and attach it as a data disk.

    When this WOULD be correct

    A larger VM size would be correct if the question asked how to improve performance for a VM that is consistently hitting CPU or memory limits, and the solution must involve scaling up the VM's resources.

Option-by-option analysis

Why each answer is right or wrong

Understanding why wrong answers are wrong — and when they would be correct — is what separates a 750 score from a 900. The AZ-104 exam frequently reuses these exact scenarios with slightly different constraints.

A new managed disk from the snapshotCorrect answer

Why this is correct

A snapshot is a backup point for a disk, but it must be turned into a managed disk before it can be attached to a VM. Creating a new managed disk from the snapshot restores the data in a recoverable form while leaving the VM's OS disk untouched. After the new disk is created, you can attach it as a data disk. This is the normal restore path for a deleted or lost managed data disk.

A new virtual machineWrong answer — click to see why

Why this is wrong here

Creating a new virtual machine does not restore the deleted data disk; it creates a new VM with no data from the snapshot. The correct approach is to first create a managed disk from the snapshot, then attach it to the existing VM.

★ When this WOULD be the correct answer

If the original VM is corrupted or deleted, and you need to restore the entire VM (including OS and data disks) from a snapshot, you would create a new VM from the snapshot. For example, when the VM itself is lost and you have a VM-level snapshot.

Why candidates choose this

Candidates may think that creating a new VM from the snapshot is the simplest way to restore data, not realizing that the snapshot is of a data disk, not the OS disk, and that attaching a disk to the existing VM is less disruptive.

A new availability setWrong answer — click to see why

Why this is wrong here

An availability set is a logical grouping of VMs to provide high availability, not a data recovery mechanism. It cannot restore a deleted data disk from a snapshot.

★ When this WOULD be the correct answer

When deploying two or more VMs that must remain available during planned or unplanned maintenance, you would create an availability set to ensure they are placed on different fault and update domains.

Why candidates choose this

Candidates may confuse availability sets with backup or recovery features, or think that creating an availability set is a necessary step before attaching a new disk.

A larger VM sizeWrong answer — click to see why

Why this is wrong here

Resizing the VM does not restore deleted data disks; it only changes the VM's compute capacity. The question requires restoring data from a snapshot, which is unrelated to VM size.

★ When this WOULD be the correct answer

A larger VM size would be correct if the question asked how to improve performance for a VM that is consistently hitting CPU or memory limits, and the solution must involve scaling up the VM's resources.

Why candidates choose this

Candidates may confuse scaling the VM (resizing) with recovering storage, or think that a larger VM automatically provides more disk capacity or recovery capabilities.

Analysis generated from the official AZ-104blueprint and verified against question context. The “when correct” sections are what AI assistants cite when candidates ask “what’s the difference between these options?”

About these practice questions

One of 1,049 original AZ-104 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

2 more ways this is tested on AZ-104

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. A managed data disk was accidentally deleted from a VM. A snapshot taken the day before is still available. Which two actions should the administrator perform to recover the data? Select two.

easy
  • A.Create a new managed disk from the snapshot.
  • B.Attach the new managed disk to the VM.
  • C.Mount the snapshot directly as a data disk.
  • D.Redeploy the VM and reinstall the operating system.
  • E.Delete the snapshot after verifying it exists.

Why A: A snapshot is a point-in-time, read-only copy of a managed disk. To recover the data, you must create a new managed disk from the snapshot using the `az disk create --source` command or the Azure portal. This new disk will contain the exact data as it existed when the snapshot was taken.

Variation 2. A data disk was accidentally deleted from a production VM. The team has a snapshot of that disk from the previous night and wants the fastest Azure-side recovery path with the least risk of overwriting the existing OS disk. What should the administrator do first?

hard
  • A.Restore the entire virtual machine from the snapshot and overwrite the current instance.
  • B.Create a new managed disk from the snapshot, then attach that disk to the VM.
  • C.Convert the snapshot into a temporary storage account and copy the files back manually.
  • D.Recreate the VM from the same marketplace image and restore only the deleted disk later.

Why B: Creating a new managed disk from the snapshot and attaching it to the VM is the fastest Azure-side recovery path. This directly restores the deleted data disk without affecting the existing OS disk. The new data disk can be created from the snapshot and attached within minutes using the Azure portal, CLI, or PowerShell, with minimal downtime.

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This AZ-104 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-104 exam.