The cinderclient.v2.volume_snapshots Module

Volume snapshot interface (1.1 extension).

class cinderclient.v2.volume_snapshots.Snapshot(manager, info, loaded=False)

Bases: cinderclient.base.Resource

A Snapshot is a point-in-time snapshot of an openstack volume.

delete()

Delete this snapshot.

progress
project_id
update(**kwargs)

Update the name or description for this snapshot.

class cinderclient.v2.volume_snapshots.SnapshotManager(api)

Bases: cinderclient.base.ManagerWithFind

Manage Snapshot resources.

create(volume_id, force=False, name=None, description=None)

Create a snapshot of the given volume.

Parameters:
  • volume_id – The ID of the volume to snapshot.
  • force – If force is True, create a snapshot even if the volume is

attached to an instance. Default is False. :param name: Name of the snapshot :param description: Description of the snapshot :rtype: Snapshot

delete(snapshot)

Delete a snapshot.

Parameters:snapshot – The Snapshot to delete.
get(snapshot_id)

Get a snapshot.

Parameters:snapshot_id – The ID of the snapshot to get.
Return type:Snapshot
list(detailed=True, search_opts=None)

Get a list of all snapshots.

Return type:list of Snapshot
resource_class

alias of Snapshot

update(snapshot, **kwargs)

Update the name or description for a snapshot.

Parameters:snapshot – The Snapshot to delete.

This Page