Skip to content

ezgh compute instances detach-volume

Detach a volume from an instance.

Updated View as Markdown
ezgh compute instances detach-volume <instance> <volume> [--force [--yes]] [--wait] [flags]

Detach a volume (by ID, UUID or name) from an instance; it becomes available. The root volume can’t be detached. On a stopped instance it’s done at once. On a running instance it’s asynchronous and waits for the guest to release the disk (unmount it first): ezgh prints the DetachVolume operation, or with --wait waits for it and prints the instance. --force frees the volume whether or not the guest releases it, and escalates a detach already under way: force detaching can lose data the instance hasn’t written to the volume, and the instance sees I/O errors. Use it only when a normal detach is stuck. --force asks first on a terminal; --yes confirms otherwise.

Part of ezgh compute instances.

Flags

Flag Type Default Description
--force boolean on a running instance, free the volume without the guest (it can lose unwritten data)
--wait boolean on a running instance, wait until it’s detached, and print the instance then
--wait-timeout duration 10m0s how long --wait waits
-y, --yes boolean don’t ask for confirmation of --force

This command also takes the global flags.

Navigation

Type to search…

↑↓ navigate↵ selectEsc close