Rename, tag, and delete volumes
Rename a volume, also while it's attached, organize volumes with tags, and delete volumes one at a time or several at once.
Rename a volume to keep its name meaningful, tag volumes to organize them, and delete the volumes that you no longer need. A volume is billed until you delete it.
Before you begin
- You need the Owner or Contributor role, or a custom role with Manage access to Block & Object Storage, on the subscription or on the project.
Rename a volume
In the console, go to StorageVolumes, and select the volume.
Select Rename.
In Volume name, enter the new name, and select Save.
The volume keeps its ID, size, type, and attachment. You can rename a volume while it's attached to an instance.
| Rule | Details |
|---|---|
| Name in the console | 1–63 characters: lowercase letters, numbers, and hyphens. |
| Name with the API | 1–255 characters, with the same rules as when you create a volume. See Create a volume. |
| Uniqueness | No other volume in the project can have the name. |
| Status | A volume that doesn't exist in the cloud yet, for example while it's being created, can't be renamed. |
To rename a volume with the API, use PATCH/scopes/{scopeId}/storage/volumes/{volumeId}.
Tag a volume
On the volume's page, select the Tags tab, and select Edit.
Change the tags: select Add tag to add one, edit a key or a value, or select × next to a tag to remove it.
Select Save.
Saving replaces the volume's whole tag set with the tags in the editor, and rows without a key are dropped. Tags on volumes follow the same rules as tags on instances. See Tag rules.
Volume costs don't carry tags. When you group costs by tag in Cost Explorer, volume storage appears as Untagged.
Delete a volume
Caution
Deleting a volume deletes all its data, and it can't be undone.
In the console, go to StorageVolumes, and select the volume.
Select Delete, and select Delete again to confirm.
You can also start from the volume list: open the actions menu (⋯) at the end of the volume's row, and select Delete.
The volume disappears from the list when the deletion finishes, and its billing stops. If the deletion is refused, the console shows the reason, and the volume stays in your project.
If the volume's creation was canceled, the volume shows Operation cancelled — leftover resources may remain, and the delete action is named Clean up. It removes what the canceled creation left in the cloud.
To delete a volume with the API, use DELETE/scopes/{scopeId}/storage/volumes/{volumeId}.
Delete several volumes
In the console, go to StorageVolumes, and select the check boxes of the volumes.
Select Delete, and select Delete again to confirm.
If some of the volumes can't be deleted, the console reports how many, with the reasons. The other volumes are deleted.
What blocks a deletion
| Cause | Message | What to do |
|---|---|---|
| Deletion protection is on. | "volume has deletion protection enabled; turn it off before deleting" | Turn off deletion protection. See Turn deletion protection on or off. |
| The volume is attached to an instance. | "volume is attached to an instance and must be detached first" | Detach the volume. To remove the OS disk of an instance, delete the instance. See Delete an instance. |
| The volume has volume snapshots. | "volume has snapshots and cannot be deleted; delete the volume's snapshots first" | Delete the volume's snapshots. See Delete a volume snapshot. |
| Restore points or images that were captured from the instance keep copies of the volume in the cloud. | "volume still has dependent snapshots in the cloud and cannot be deleted; delete the snapshots and any machine image captured from this volume first" | Delete those restore points and images, and then delete the volume. See Delete a restore point and Delete an image. |
Troubleshooting
| Message | Cause | What to do |
|---|---|---|
| "a volume with this name already exists" | Another volume in the project has the new name. | Enter another name. |
| "volume is not ready (still provisioning); retry once it is AVAILABLE" | The volume doesn't exist in the cloud yet. | Wait until the volume is Available, and rename it again. |
| "tag keys must be unique" | Two tags have the same key. | Remove one of them, or change its key. |