Usage
uc volume remove, uc volume delete
Arguments
Names of volumes to remove. Can specify multiple volumes.
Flags
-f, --force
Force the removal of one or more volumes.
Name or ID of the machine to remove volume(s) from. Can be specified multiple times or as a comma-separated list. If not specified, the found volume(s) will be removed from all machines.
-y, --yes
Do not prompt for confirmation before removing the volume(s).
Examples
Remove a volume (with confirmation)
Remove a volume without confirmation
Remove multiple volumes
Remove a volume from a specific machine
If a volume with the same name exists on multiple machines:Force remove a volume
Remove even if in use (may cause errors):Confirmation
By default, you’ll be asked to confirm before removing volumes:-y:
Important Notes
Data Loss Warning
Removing a volume permanently deletes all data stored in it. This action cannot be undone.Volumes in Use
You cannot remove a volume that’s currently in use by a container:--force to override (not recommended):
Multiple Machines
If a volume name exists on multiple machines, all instances are removed unless you specify--machine:
Output
Use Cases
Clean Up After Service Removal
After removing a service, clean up its volumes:Free Up Disk Space
Remove unused volumes to free disk space:Start Fresh
Remove and recreate a volume to reset data:Related Commands
uc volume create- Create a volumeuc volume ls- List volumesuc service rm- Remove services that use volumes
