openstack.block_store.v2.volume¶
The Volume Class¶
The Volume class inherits from Resource.
-
class
openstack.block_store.v2.volume.Volume(attrs=None, loaded=False)¶ Construct a Resource to interact with a service’s REST API.
The Resource class offers two class methods to construct resource objects, which are preferrable to entering through this initializer. See
Resource.new()andResource.existing().Parameters: - attrs (dict) – The attributes to set when constructing this Resource.
- loaded (bool) –
Trueif this Resource exists on the server,Falseif it does not.
-
id= None¶ A ID representing this volume.
-
name= None¶ The name of this volume.
-
links= None¶ A list of links associated with this volume. Type: list
-
availability_zone= None¶ The availability zone.
-
source_volume_id= None¶ To create a volume from an existing volume, specify the ID of the existing volume. If specified, the volume is created with same size of the source volume.
-
description= None¶ The volume description.
-
snapshot_id= None¶ To create a volume from an existing snapshot, specify the ID of the existing volume snapshot. If specified, the volume is created in same availability zone and with same size of the snapshot.
-
size= None¶ The size of the volume, in GBs. Type: int
-
image_id= None¶ The ID of the image from which you want to create the volume. Required to create a bootable volume.
-
volume_type= None¶ The name of the associated volume type.
-
bootable= None¶ Enables or disables the bootable attribute. You can boot an instance from a bootable volume. Type: bool
-
metadata= None¶ One or more metadata key and value pairs to associate with the volume.
-
status= None¶ One of the following values: creating, available, attaching, in-use deleting, error, error_deleting, backing-up, restoring-backup, error_restoring. For details on these statuses, see the Block Storage API documentation.
-
attachments= None¶ TODO(briancurtin): This is currently undocumented in the API.
-
created= None¶ The time this volume was created at.
The VolumeDetail Class¶
The VolumeDetail class inherits from
Volume.
-
class
openstack.block_store.v2.volume.VolumeDetail(attrs=None, loaded=False)¶ Construct a Resource to interact with a service’s REST API.
The Resource class offers two class methods to construct resource objects, which are preferrable to entering through this initializer. See
Resource.new()andResource.existing().Parameters: - attrs (dict) – The attributes to set when constructing this Resource.
- loaded (bool) –
Trueif this Resource exists on the server,Falseif it does not.
-
host= None¶ The volume’s current back-end.
-
project_id= None¶ The project ID associated with current back-end.
-
migration_status= None¶ The status of this volume’s migration (None means that a migration is not currently in progress).
-
migration_id= None¶ The volume ID that this volume’s name on the back-end is based on.
-
replication_status= None¶ Status of replication on this volume.
-
extended_replication_status= None¶ Extended replication status on this volume.
-
consistency_group_id= None¶ ID of the consistency group.
-
replication_driver_data= None¶ Data set by the replication driver
-
encrypted= None¶ Trueif this volume is encrypted,Falseif not. Type: bool