<p>I am following <a href="https://docs.aws.amazon.com/eks/latest/userguide/efs-csi.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/eks/latest/userguide/efs-csi.html</a> to link EFS to EKS.
I have two namespace under my k8s clusters: <code>dev</code> and <code>stage</code>, and from I understand, I'd need to have two PersistentVolumeClaims that map to the shared PersistentVolume and StorageClass. So after I ran below 3 commands:</p>
<pre><code>kubectl apply -f specs/pv.yaml
kubectl apply -f specs/claim.yaml
kubectl apply -f specs/storageclass.yaml
</code></pre>
<p>and from <code>kubectl get sc,pv,pvc1 -n dev</code>, I am able to see all 3 items just fine. However, as I tried to add to <code>stage</code> namespace - <code>kubectl apply -f specs/claim.yaml --namespace=stage</code>, I got below errors as <code>efs-claim</code> becomes stuck in a forever PENDING status:</p>
<pre><code>Name:          efs-claim
Namespace:     stage
StorageClass:  efs-sc
Status:        Pending
Volume:        
Labels:        &lt;none&gt;
Annotations:   volume.beta.kubernetes.io/storage-provisioner: efs.csi.aws.com
Finalizers:    [kubernetes.io/pvc-protection]
Capacity:      
Access Modes:  
VolumeMode:    Filesystem
Used By:       foo-api-stage-chart-12345-abcde
               foo-api-stage-chart-12345-abcde
Events:
  Type     Reason                Age                From                                                                              Message
  ----     ------                ----               ----                                                                              -------
  Normal   Provisioning          107s               efs.csi.aws.com_ip-xxx  External provisioner is provisioning volume for claim &quot;stage/efs-claim&quot;
  Warning  ProvisioningFailed    107s               efs.csi.aws.com_ip-xxx  failed to provision volume with StorageClass &quot;efs-sc&quot;: rpc error: code = InvalidArgument desc = Missing provisioningMode parameter
  Normal   ExternalProvisioning  4s (x8 over 107s)  persistentvolume-controller                                                       waiting for a volume to be created, either by external provisioner &quot;efs.csi.aws.com&quot; or manually created by system administrator
</code></pre>
<p>What is causing</p>
<blockquote>
<p>efs.csi.aws.com_ip-xxx  failed to provision volume with StorageClass &quot;efs-sc&quot;: rpc error: code = InvalidArgument desc = Missing provisioningMode parameter</p>
</blockquote>
<p>I did not have to provide such parameter on <code>dev</code> namespace so why it is required for a different namespace like <code>stage</code>?</p>

<p>To resolve the error that you are seeing, re-apply your StorageClass with:</p>
<pre><code>...
parameters:
  provisioningMode: efs-ap
  fileSystemId: &lt;ID of the file system created on EFS&gt;
...
</code></pre>
<p>If multiple pods going to read/write to the file system, re-apply PersistentVolume with:</p>
<pre><code>...
spec:
  ...
  accessModes:
  - ReadWriteMany
...
</code></pre>
<p>Should the problem persist do post your StorageClass, PersistentVolumeClaim and PersistentVolume spec in your question.</p>
