Hello @Stephen Weber ,
Yeah ! That's the right way to find out if the disk is in use or not .
Here are the detailed answers for your questions with screen shot in my local testing:
List of disks in my subscription:
If you click on any of the disks for which you see the owners , please observe below highlighted ones:
Disk State: Reserved
Managed By : Master (i.e. the VM name which is currently using this disk)
Operating system: Since myne was the Linux OS VM disk
Please Note: The delete button is disabled (Because it is actively in use)
Comparing to the one of the disk which is NOT in use:
Disk State: UnAttached
Managed By : -
Operation System: -
Lets say if you previously had a Virtual Machine which is using the disk and you have deleted the VM but the OS disk was not deleted, then in those scenarios the disk screen shot looks like below:
Disk State: Unattached (currently disk is not attached , hence it can be deleted)
Managed By: -
Operating System: Linux (Previously it was being used by Linux VM)
To summarize :-
- From portal you can't delete a disk which is in use. You can use powershell to delete the disk but it will fail with error "Disk in Use"
- To identify if the disk is in use or not : You can see owner or You can see the disk state. Kindly let us know if you have any additional questions, happy to help out ! Regards, Shiva.