Persistent Volume Claim state stuck in pending state for volume with access mode as Read Write Many
search cancel

Persistent Volume Claim state stuck in pending state for volume with access mode as Read Write Many

book

Article ID: 414395

calendar_today

Updated On:

Products

VMware vSphere Kubernetes Service

Issue/Introduction

  • PVC status shows as pending in UI under Namespace > Resources > Volume Service.
  • Running the below command on Supervisor shows volume status as Pending:
    k get pvc -A

  • vsphere-csi-controller logs show the below entries:

    "Event occurred" object="<guest_cluster_name>/<volume_name>" fieldPath="" kind="PersistentVolumeClaim" apiVersion="v1" type="Warning" reason="ProvisioningFailed" message="failed to provision volume with StorageClass \"vsan-default-storage-policy\": rpc error: code = Unimplemented desc = file services are disabled on supervisor cluster"
    Event occurred" object="<guest_cluster_name>/<volume_name>" fieldPath="" kind="PersistentVolumeClaim" apiVersion="v1" type="Warning" reason="ProvisioningFailed" message="failed to provision volume with StorageClass \"kubernetes-storage-policy-thin\": rpc error: code = Unimplemented desc = file services are disabled on supervisor cluster"

  • Access mode for the volume is configured as RWX (Read Write Many).
  • PVC gets successfully Bound if the access mode of the PVC is changed to RWO (Read Write Once).
  • vSAN File share Service is Not Enabled.

Environment

  • VMware vSphere Kubernetes Service 9.0
  • VMware vSphere Kubernetes Service 8.0

Cause

  • For volumes configured with access mode as RWX (Read Write Many), vSAN File Share Service is a requirement, which is not met in this scenario.

Resolution

  • Enable vSAN file service on the vSAN cluster. 
  • Make sure that the File Volume is enabled on the Supervisor. Supervisor > Configure > Storage > File Volume.

Note: VMFS is not supported for PVC with access mode configured as RWX(Read Write Many). The Supervisor uses CNS file volumes backed by vSAN file shares for the ReadWriteMany persistent volumes in vSphere Supervisor Environment. Using vSAN File Service to Create ReadWriteMany Volumes in Supervisor Environment