Deleting resources
A resource will not delete
A delete is refused while other resources are attached to the one you are deleting. Pressing delete opens a dialog first that lists those attached resources — type, name, ID, and a link to the detail page, with the name and ID available to copy.
There are two kinds of relationship, and they are resolved differently.
- Attached — the dialog can detach it for you. See below
- In use — you have to clear the other resource first. See below
If you clear a connection from another screen, use Refresh in the dialog to re-read the list.
When does "Detach and delete" appear?
A resource that is simply attached can be detached from the dialog. The confirm button becomes Detach and delete, and running it detaches and then deletes, in that order.
| Deleting | What gets detached |
|---|---|
| Public IP | The attached network interface |
| Block storage | The attached virtual machine |
| Network interface | The attached virtual machine and public IP |
Multiple attachments are detached in order, and if any one of them fails the delete does not run. Clear the failed attachment and try again.
The dialog does not offer to detach, and the delete is blocked instead. Someone with permission has to detach it first.
The delete button is disabled
Either the name has not been typed yet, or an attachment remains that the dialog cannot clear.
When other resources are using the one you are deleting, the dialog cannot clear them for you. It lists them with links and leaves the delete button disabled.
| Deleting | Clear first |
|---|---|
| Virtual network | The subnets created inside it |
| Subnet | The network interfaces using that subnet |
| Block storage | The snapshots taken from that disk |
| Snapshot | The block storage created from that snapshot |
| Object storage bucket | The access grants on the bucket |
| Public IP | The load balancer using that IP |
Follow a link, clear the resource, then use Refresh to check again.
Can I delete a disk attached to a running virtual machine?
Stop the virtual machine first. While it is running the detach is asynchronous and can race the delete.
If a detach has already been requested, there is nothing left to detach — wait for it to finish, then delete.
Why do I have to type the name to delete?
It is a confirmation step that prevents accidental deletion. The delete button is enabled only after you type the name of the resource; use the copy button next to the name shown above the field.
It applies to deleting public IPs, network interfaces, subnets, virtual networks, load balancers, block storage, snapshots, snapshot schedulers, object storage buckets and users, and parallel file systems (PFS). Stopping a virtual cluster asks for the same confirmation.
Next steps
- Block storage: attaching, detaching, and snapshots
- Public IP: attaching and detaching interfaces
- Network interface: attaching to and detaching from a virtual machine