# Azure VM Using Unmanaged Disks

> Flags Azure VMs whose OS disk is still an unmanaged VHD, a disk type retired on 31 March 2026 that can no longer start.

Source: https://zop.dev/integrations/azure/recommendations/azure-vm-using-unmanaged-disks

---

## Unmanaged disks are past their retirement date

Before managed disks arrived in 2017, a VM disk was a VHD file stored as a page blob in a
storage account you created and sized yourself. Microsoft announced the retirement of unmanaged
disks on 13 September 2022, and
[the retirement completed on 31 March 2026](https://learn.microsoft.com/en-us/azure/virtual-machines/unmanaged-disks-deprecation).
After that date, IaaS VMs that use unmanaged disks cannot be started, and any that were running
or allocated are stopped and deallocated.

A VM that still fires this rule is either already down or one stop away from being unable to
come back.

## Finding VMs on unmanaged disks

```bash
az vm list \
  --query "[?storageProfile.osDisk.managedDisk==null].{name:name, rg:resourceGroup, vhd:storageProfile.osDisk.vhd.uri}" \
  -o table
```

A `vhd` URI pointing at a `blob.core.windows.net` address confirms an unmanaged OS disk.

## What makes ZopNight fire

ZopNight looks at whether the VM's OS disk definition includes a managed disk and fires when
Azure reports that it does not. The check reads the OS disk only; there is no metric or window.

## When no finding appears

If the OS disk's managed state could not be determined, the VM is left alone. Tags are not read.
VMs with a managed OS disk are clear, even if they have unmanaged data disks attached, so check
data disks separately with `az vm show --query storageProfile.dataDisks`.

## An availability emergency, not a saving

No saving is claimed. The consequence of ignoring this is a VM that cannot run. Managed disks
also remove the storage account capacity planning that unmanaged disks required.

## Converting to managed disks

1. Snapshot or back up the VHD blobs if you have no recent copy.
2. Deallocate the VM: `az vm deallocate --resource-group my-rg --name my-vm`.
3. Convert all its disks: `az vm convert --resource-group my-rg --name my-vm`.
4. Start the VM and verify the application.
5. Once you are satisfied, delete the old VHD blobs; they keep billing as storage until removed.

See [Migrate Azure VMs to managed disks](https://learn.microsoft.com/en-us/azure/virtual-machines/windows/migrate-to-managed-disks)
for availability set and scale set specifics.

**Warning**
Deleting the source VHD blobs is irreversible. Confirm the converted VM boots and its data
is intact first.
