nova/doc/source/admin/manage-volumes.rst
chenxing 575b529118 doc: Import administration guide
Import all docs from openstack-manuals.

Part of bp: doc-migration

Change-Id: I28bb8ce1f4a8653f176a554d2e95b4423c437972
Co-Authored-By: Stephen Finucane <sfinucan@redhat.com>
2017-08-04 07:00:45 -04:00

1.6 KiB

Manage volumes

Depending on the setup of your cloud provider, they may give you an endpoint to use to manage volumes, or there may be an extension under the covers. In either case, you can use the openstack CLI to manage volumes.

openstack volume commands
Command Description
server add volume Attach a volume to a server.
volume create Add a new volume.
volume delete Remove or delete a volume.
server remove volume Detach or remove a volume from a server.
volume list List all the volumes.
volume show Show details about a volume.
snapshot create Add a new snapshot.
snapshot delete Remove a snapshot.
snapshot list List all the snapshots.
snapshot show Show details about a snapshot.
volume type create Create a new volume type.
volume type delete Delete a specific flavor
volume type list Print a list of available 'volume types'.

For example, to list IDs and names of volumes, run:

$ openstack volume list
+--------+--------------+-----------+------+-------------+
| ID     | Display Name | Status    | Size | Attached to |
+--------+--------------+-----------+------+-------------+
| 86e6cb | testnfs      | available |    1 |             |
| e389f7 | demo         | available |    1 |             |
+--------+--------------+-----------+------+-------------+