vmware-tanzu / velero

Backup and migrate Kubernetes applications and their persistent volumes
https://velero.io
Apache License 2.0
8.63k stars 1.39k forks source link

CSI snapshot feature with velero - webhook "snapshot-validation-webhook.snapshot.storage.k8s.io" denied the request: Spec.SourceVolumeMode is immutable #7771

Open radhika-pr opened 4 months ago

radhika-pr commented 4 months ago

What steps did you take and what happened: I have a cluster onpremise and the velero is installed with CSISnapshot feature to enable snapshot of Ontap -trident volumes. .

velero create backup test-pol-csi-snap-5 --include-namespaces test-policy --snapshot-move-data

The second time I run the command on same namespace, the backup creation fails with below error.

Operation Error:       error to expose snapshot: error to remove protect from volume snapshot content: error to update VolumeSnapshotContent snapcontent-968909c2-2a7e-4e44-9497-db1c34860b6f: admission webhook "snapshot-validation-webhook.snapshot.storage.k8s.io" denied the request: Spec.SourceVolumeMode is immutable but was changed from Filesystem to nil

What did you expect to happen: Backup created without any issues.

If you are using velero v1.7.0+:
Please use velero debug --backup <backupname> --restore <restorename> to generate the support bundle, and attach to this issue, more options please refer to velero debug --help bundle-2024-05-06-12-48-44.tar.gz

Environment:

Vote on this issue!

This is an invitation to the Velero community to vote on issues, you can see the project's top voted issues listed here.
Use the "reaction smiley face" up to the right of this comment to vote.

blackpiglet commented 4 months ago

This is already fixed. Please try with v1.13.2.

The fixed PR is #7577.