Volume snapshot does not work
Created by: matofeder
Desired state
As a KaaS user, I want to create a volume-snapshot as is described e.g. here
Current state
The volume snapshot feature is not working in the workload clusters managed by the latest (R4) version of k8s-cluster-api-provider (with the default settings, i.e. k8s version v1.25.x
)
Steps to reproduce
- Create a workload cluster by the k8s-cluster-api-provider
- use default settings ( i.e. k8s version
v1.25.x
)
- use default settings ( i.e. k8s version
- Create PVC and its snapshot (well described e.g. in this example)
- K8s objects
volumesnapshotcontents.snapshot.storage.k8s.io
andvolumesnapshots.snapshot.storage.k8s.io
are not created and volume snapshot is not created as well
Reason
Currently, the script apply_cindercsi.sh
wants to enable this feature with the deployment of related snapshot CRDs here.
Since Kubernetes version 1.17
, the CSI external-snapshotter sidecar (sidecar deployed together with CSI cinder driver) controller has been split into two controllers: a snapshot-controller (an independent controller of any CSI Driver) and a CSI external-snapshotter sidecar (sidecar deployed together with CSI cinder driver).
Therefore the snapshot-controller should be deployed as well as part of k8s cluster management process to enable the volume snapshot feature in the k8s cluster.
Posible solution
Update the apply_cindercsi.sh
script and deploy the snapshot-controller as is described e.g. here