You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When PV and PVC are already dynamically allocated, do the following operation to make the PVC using a selector to filter the PV. Then create a Velero backup with the Velero CSI plugin, and restore from the backup. The restore will success, but the PVC and related Pod are always in a Pending state due to no available PV can be found.
Change the Reclaim policy to Retain: kubectl patch pv <your-pv-name> -p '{"spec":{"persistentVolumeReclaimPolicy":"Retain"}}'
Tag the PV: kubectl label pv <pv-name> <key=pair>
Delete the PVC and modify it to use labels to invoke the PV just labeled
Change the PV to Available state: kubectl patch pv <pv-name> -p '{"spec":{"claimRef": null}}'
Deploy the PVC modified to invoke PV using labels.
# k -n restore describe pvc my-pvcName: my-pvcNamespace: restoreStorageClass: standard-rwoStatus: PendingVolume:
Labels: app=hello-appbackup.velero.io/must-include-additional-items=truevelero.io/backup-name=3240504-testvelero.io/restore-name=3240504-test-20230630061156velero.io/volume-snapshot-name=velero-my-pvc-6qshvAnnotations: backup.velero.io/must-include-additional-items: truevelero.io/backup-name: 3240504-testvelero.io/volume-snapshot-name: velero-my-pvc-6qshvvolume.beta.kubernetes.io/storage-provisioner: pd.csi.storage.gke.iovolume.kubernetes.io/selected-node: <node-name>volume.kubernetes.io/storage-provisioner: pd.csi.storage.gke.ioFinalizers: [kubernetes.io/pvc-protection]Capacity:
Access Modes:
VolumeMode: FilesystemDataSource:
APIGroup: snapshot.storage.k8s.ioKind: VolumeSnapshotName: velero-my-pvc-6qshvUsed By: hello-app-7579d6745b-nzjlxEvents:
Type Reason Age From Message---- ------ ---- ---- -------Normal WaitForFirstConsumer 37s (x2 over 37s) persistentvolume-controller waiting for first consumer to be created before bindingNormal Provisioning 6s (x6 over 37s) External provisioner is provisioning volume for claim "restore/my-pvc"Warning ProvisioningFailed 6s (x6 over 37s) failed to provision volume with StorageClass "standard-rwo": claim Selector is not supportedNormal ExternalProvisioning 3s (x4 over 37s) persistentvolume-controller waiting for a volume to be created, either by external provisioner "pd.csi.storage.gke.io" or manually created by system administrator
Describe the solution you'd like
Although this issue is triggered by a hacking way to create PV and PVC, need to consider whether there is a way to make CSI restore in the scenario.
Anything else you would like to add:
Environment:
Velero version (use velero version): v1.12
Kubernetes version (use kubectl version): v1.25
Kubernetes installer & version: GKE
Cloud provider or hardware configuration: GCP
OS (e.g. from /etc/os-release): Debian
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.
👍 for "The project would be better with this feature added"
👎 for "This feature will not enhance the project in a meaningful way"
The text was updated successfully, but these errors were encountered:
IMO we may want to remove the label selector from pvc when we apply the dynamic provision (podvolume/CSI).
Curious if there are provisioners which indeed support the selector in pvc and what's the behavior.
Describe the problem/challenge you have
When PV and PVC are already dynamically allocated, do the following operation to make the PVC using a
selector
to filter the PV. Then create a Velero backup with the Velero CSI plugin, and restore from the backup. The restore will success, but the PVC and related Pod are always in aPending
state due to no available PV can be found.kubectl patch pv <your-pv-name> -p '{"spec":{"persistentVolumeReclaimPolicy":"Retain"}}'
kubectl label pv <pv-name> <key=pair>
kubectl patch pv <pv-name> -p '{"spec":{"claimRef": null}}'
Describe the solution you'd like
Although this issue is triggered by a hacking way to create PV and PVC, need to consider whether there is a way to make CSI restore in the scenario.
Anything else you would like to add:
Environment:
velero version
): v1.12kubectl version
): v1.25/etc/os-release
): DebianVote 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.
The text was updated successfully, but these errors were encountered: