The OpenStack block storage service (Cinder) provides the ability to create raw volumes on the underlying disk. The block storage service provides a pluggable architecture wherein you can attach vendor-specific plugins for creation and manipulation of volumes. By default, the block storage service uses Linux's native Logical Volume Manager driver. In other words, when a volume is created using the block storage service, an LVM volume is created underneath.
Let's see what the Python SDK offers for interacting with the block storage service.
Let's write application programs to create and delete OpenStack volumes.
An OpenStack volume can be created by invoking the create_volume()
function call and passing properties of the volume to be created. These properties are defined using a Python dictionary.
The following properties can be defined using the Python dictionary. Only the size
parameter is mandatory and all others are optional:
id...