Volume snapshot classes
To enable dynamic snapshotting in LVMS, ensure that at least one VolumeSnapshotClass configuration file is present on the node. This resource defines the Container Storage Interface (CSI) parameters required to create and manage volume snapshots.
|
|
You must enable thin logical volumes to take logical volume snapshots. |
VolumeSnapshotClass configuration fileapiVersion: snapshot.storage.k8s.io/v1
kind: VolumeSnapshotClass
metadata:
name: topolvm-snapclass
annotations:
snapshot.storage.kubernetes.io/is-default-class: "true"
driver: topolvm.io
deletionPolicy: Delete
where:
snapshot.storage.kubernetes.io/is-default-class-
Specifies the
VolumeSnapshotClassconfiguration file to use when none is specified byVolumeSnapshot. WhereVolumeSnapshotis a request for snapshot of a volume by a user. driver-
Identifies the snapshot provisioner that manages the requests for snapshots of a volume by a user for this class.
deletionPolicy-
Specifies the
VolumeSnapshotContentobjects and the backing snapshots that are kept or deleted when a boundVolumeSnapshotis deleted. Valid values areRetainorDelete.