Hi jack,
an OS Disk can't be detached from a VM.
The work around for it is you could export the OS Disk:
- Stop/Deallocate the VM
- Navigate to
Disks
and click on the OS Disk - Click on
Disk Export
andGenerate URL
- Depending on the size of the disk and the internet bandwidth you should extend the URL expiration time - Use the generated URL to start the download
for more information and detailed explanation you can look into the below previous thread
https://learn.microsoft.com/en-us/answers/questions/938670/how-to-deattach-an-os-disk
https://learn.microsoft.com/en-us/answers/questions/1418887/how-to-detach-azure-vmss-os-disk
https://learn.microsoft.com/en-us/answers/questions/2264013/how-to-reattach-an-os-disk-after-detaching-from-a
Feel free to reach out if you have any further queries.
If you found the information useful, please click "Accept answer" and "Upvote" on the post to let us know.
Thank You