
Let's say something like this is being returned.
cns query volume did not return the volume: pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2
I got this when attempting to create a volume snapshot. Check out my article OpenShift - Create Volume Snapshot. Describing the Volume Snapshot shows that the snapshot is using Volume Snapshot Class csi-vsphere-vsc. This stands for Container Storage Interface (CSI) VMWare vSphere Virtual Storage Console (VSC).
~]$ oc describe volumesnapshot my-volume-snapshot --namespace my-project
Name: my-volume-snapshot
Namespace: my-project
Labels: <none>
Annotations: <none>
API Version: snapshot.storage.k8s.io/v1
Kind: VolumeSnapshot
Metadata:
Creation Timestamp: 2025-04-24T01:08:12Z
Finalizers:
snapshot.storage.kubernetes.io/volumesnapshot-as-source-protection
snapshot.storage.kubernetes.io/volumesnapshot-bound-protection
Generation: 1
Resource Version: 504423472
UID: 5e9a4545-76d9-4c0d-bc50-cb54d5d7cc76
Spec:
Source:
Persistent Volume Claim Name: my-pvc
Volume Snapshot Class Name: csi-vsphere-vsc
Status:
Bound Volume Snapshot Content Name: snapcontent-5e9a4545-76d9-4c0d-bc50-cb54d5d7cc76
Error:
Message: Failed to check and update snapshot content: failed to take snapshot of the volume pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2: "rpc error: code = Internal desc = cns query volume did not return the volume: pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2"
Time: 2025-04-24T01:08:13Z
Ready To Use: false
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal CreatingSnapshot 10m snapshot-controller Waiting for a snapshot my-project/my-volume-snapshot to be created by the CSI driver
Notice in this example that the Persistent Volume Claim is pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2. The oc get pv command can be used to locate the Persistent Volume. Notice in this example that the Persistent Volume Storage Class is file-storage but the Volume Snapshot has Volume Snapshot Class csi-vsphere-vsc.
~]$ oc get pv pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2
NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS VOLUMEATTRIBUTESCLASS REASON AGE
pvc-c9189553-5082-4d00-b8c8-715bbf76f4f2 1Gi RWO Delete Bound my-project/my-pvc file-storage <unset> 127d
The Persistent Volume can be describe which shows indeed the Persistent Volume is using driver csi.trident.netapp.io. So that's the root cause of the issue here, the Volume Snapshot was made using the wrong Drive / Storage Class. This can probably be resolved by updating the Volume Snapshot to use the correct Driver / Storage Class, csi.trident.netapp.io in this example.
Did you find this article helpful?
If so, consider buying me a coffee over at